Understanding Virtual Attributes and get/set methods

Comparing #4 with #5

Revision #5 was created by abajja abajja on Mar 31, 2011, 9:54:43 AM.

minor typo

Content

[...]
$model->active = 1;
$model->setActive(1); // same thing
```

Note that Yii uses get/set functions **very** heavily internally, so when reviewing the class refer
nences, any function beginning with "set" or "get" can generally be used as an attribute.>

Resolving Conflicts
-------------------
When using an attribute name -- `$model->foo` -- it's important to know the order in which they are processed, because **duplicates are not generally detected**, and this can cause all kinds of hard-to-find bugs.
[...]