Erkana My_Controller quick question |
[eluser]efx[/eluser]
I'm having trouble creating a controller than extends the auth_controller. I get the fatal error: Call to a member function view() on a non-object in F:\web\www\mush\system\application\controllers\test.php on line 12 The code for the controller is: Code: <?php MY_Controller lib: Code: <?php if (!defined('BASEPATH')) exit('No direct access allowed.'); It's gotta be something simple that i'm missing. Ive tried both Test() & __construct() for the constructor call. Any ideas?
[eluser]Rick Jolly[/eluser]
You're missing the call to parent:ublic_Controller(); in the Auth_Controller constructor. You should be calling parent:ublic_Controller(); instead of parent::Controller(); in the Admin_Controller constructor.
[eluser]Michael Wales[/eluser]
Yeah - sorry about that, I think that's a minor mistake in the downloadable version from my blog. It will be fixed soon - everything on my blog is getting an overhaul. |
Welcome Guest, Not a member yet? Register Sign In |