![]() |
Input class doesn't seem to be loading?? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Input class doesn't seem to be loading?? (/showthread.php?tid=41528) |
Input class doesn't seem to be loading?? - El Forum - 05-10-2011 [eluser]minerbog[/eluser] Hi All, I have the following code below that I am creating for my website. For some reason it returns an error on line 8 "Thats the $this->input->ip_address();" line. The error return is Code: A PHP Error was encountered And the code is Code: <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); Any ideas?? I thought the input class was loaded automatically?? Cheers, Gavin Input class doesn't seem to be loading?? - El Forum - 05-10-2011 [eluser]Italo Domingues[/eluser] In the constructor method put parent::__construct() You do not need Code: $CI =& get_instance(); Use Code: $this->config->config['base_url'] = str_replace('http://', 'https://', $this->config->config['base_url']); Input class doesn't seem to be loading?? - El Forum - 05-10-2011 [eluser]toopay[/eluser] Code: parent::__construct(); Input class doesn't seem to be loading?? - El Forum - 05-10-2011 [eluser]minerbog[/eluser] ![]() Opps, Why do you always miss the obvious!! Thanks Guys Input class doesn't seem to be loading?? - El Forum - 05-10-2011 [eluser]InsiteFX[/eluser] In the future if you need to find out if a library has loaded just add this code to your controller: Code: // Boolean TRUE = on - FALSE = off InsiteFX |