Welcome Guest, Not a member yet? Register   Sign In
Ion Auth - Lightweight Auth System based on Redux Auth 2

[eluser]Oliver Zeyen[/eluser]
hello! Hope somebody can help me!

I can't call any ion_auth methods AFTER I load a module.

I've created an ion_auth module in a slightly different way wayne described. This module works fine, all actions of the demo application work like a charm. To avoid any calls of ion_auth AFTER a module is loaded, for example my navigation module in the template controller, I've build a cascade of controllers which extend each other.

The first one, auth_controller extends the base controller and loads the ion_auth library from the module. Login status and userdata are fetched and checked by the corresponding methods of the library. I am forced do this, because any later call of ion_auth produces errors.

The second controller is my template_controller which initializes all the base templates, loads all views and holds the public render function which is called in my application controllers. In this controller, view modules are merged into my templates. And thats the point. module loaded, good bye ion_auth.

In my application controller: load ion_auth and call $this->ion_auth->get_userdata(); php gives me the following error:

"Call to a member function userdata() on a non-object in /var/www/www.myserver.de/application/modules/auth/models/ion_auth_model.php on line 726" which points to "$this->session->userdata('user_id');"

also this warning is thrown: "Message: Undefined Property: navigation::$session Filename: core/Model.php Line Number: 50"

Does anybody know a solution for this problem?

By the way: This is my second attempt... I previously installed ion_auth "conventionally" as a simple library and not as a module with the same results... errors when calling it after a module.


Messages In This Thread
Ion Auth - Lightweight Auth System based on Redux Auth 2 - by El Forum - 03-17-2011, 03:57 PM



Theme © iAndrew 2016 - Forum software by © MyBB