06-10-2012, 11:21 PM
[eluser]nebulom[/eluser]
Is there a way I can instantiate my model from helper? I would like to it like this:
Thanks.
Is there a way I can instantiate my model from helper? I would like to it like this:
Code:
# user_helper.php
function user_form_session($session) {
$user = new User_model();
$user->email = $session['email'];
$user->password = $session['password'];
return $user;
}
Thanks.