Love Fuel?
Donate
About
Forums
Discussions
Login
FuelPHP Forums
Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Auth
Extended Auth_User not found
Lisa
January 2015
Hello,
I'm trying to extend the Auth_User class. In order to do so, I've created app\classes\model\user.php:
namespace Model;
class Auth_User extends \Auth\Model\Auth_User
{
protected static $_properties = array(
'telefon_number' => array(
'label'
=> 'auth_model_user.telefon_number',
'default'
=> 0,
'null'
=> false,
),
);
}
In my app\bootstrap.php I have:
Autoloader::add_classes(array(
'Model\\Auth_User' => APPPATH.'classes/model/user.php',
'Auth_User' => APPPATH.'classes/model/user.php',
));
However, I get a "File "APPPATH/classes/model/user.php" does not contain class "Auth_User"" exception. What could have gone wrong?
Harro
January 2015
Accepted Answer
You get that message because it doesn't. It contains \Model\Auth_User.
So why add it to the autoloader twice, once correct and once incorrect?
Lisa
January 2015
Thank you, it works now.
Add a Comment
Howdy, Stranger!
It looks like you're new here. If you want to get involved, click one of these buttons!
Sign In
Apply for Membership
Categories
All Discussions
5,089
General
↳ General
3,364
↳ Job Board
13
↳ Installation & Setup
214
Packages
↳ Oil
213
↳ Orm
700
↳ Auth
261
Development
↳ Tips and Tutorials
126
↳ Code share
145
↳ Applications
52
In this Discussion
Harro
January 2015
Lisa
January 2015