How can I include or Call Session Controller In to My home page ,about page .... |
If you want to write you session check as a library, you need to put your Session_check file into the library folder:
app ----library --------Session_check.php You can load it via $this->load->library('Session_check'); , if the file is called Session_check.php. But you can't simply extends CI_Controller, you need to get an instance of CI, via get_instance(); Have a look here, if you don't know how to get CI instance. http://forum.codeigniter.com/thread-61626.html And for the purpose of learning, look here http://www.codeigniter.com/userguide3/ge...aries.html But for simpleness, just write the Content of Session_check in the same controller or write it in a MY_Controller and extend it, instead of CI_Controller. But this is just a mention. -.-.-.-.-.-.-.-.- -.-.-.-.-.-.-.-.-
|
Messages In This Thread |
How can I include or Call Session Controller In to My home page ,about page .... - by Chandini - 05-08-2015, 02:38 AM
RE: How can I include or Call Session Controller In to My home page ,about page .... - by noobie - 05-08-2015, 07:09 AM
RE: How can I include or Call Session Controller In to My home page ,about page .... - by Urastor - 05-08-2015, 07:17 AM
|