I’m using Kohana3.
For example I create instance:
$user = ORM::factory('orm_user', $user_id)
After this I can get value of each column using this syntax: $user->user_login or $user->user_password.
Can I rename this properties to get them like: $user->login or $user->pass?
I’m using Kohana3. For example I create instance: $user = ORM::factory(‘orm_user’, $user_id) After this
Share
Yes, you can overload the magic __set and __get methods in your model:
Any rules or filters you write will still need to use the original column names.