Integrating Tank_Auth library into the template library - howto ? |
[eluser]Unknown[/eluser]
looked around but could't find an example. i'm using the template library: http://williamsconcepts.com/ci/codeignit...rence.html and would like to integrate the Tank_Auth authentication module to my pages, so to have a login/logout/register form in a $topbar template region i created. Also to be able to control the display of certain regions depending on the log in status. I have tried to do this on the Welcome page Controller, but i'm stuck. getting an error "Unable to load the requested file: Array.php" can anyone lead me in the right direction ? thanks. this is what i have so far Code: class Welcome extends CI_Controller {
[eluser]Haskabab[/eluser]
Hey I use the same library and this is how I integrated Tank Auth: I edited the auth controller and replaced all Code: $this->load->view('viewNameHere', $data); with Code: $this->template->write('title', 'Auth > Login / whatever'); So you should add all the static template regions in the constructor, or add them above the template->render() method. That should work, i did that and everything is working fine!
|
Welcome Guest, Not a member yet? Register Sign In |