I am using the CodeIgniter framework for PHP. I created a view called "login.php". As soon as i
created a view, then I loaded the view inside a function called "index", which is located
inside a class called "CCI" that extends the controller, but I keep getting this error: Fatal
Error: calling the undefined site_url () function in C: \ wamp \ www \ FinalP_CCI_Clone \ system
\ application \ views \ login.php on line 12. I do not understand what I have, because
The welcome page loads fine, and my second function inside the CCI class also loads.
Here are some of the code:
Controller Files:
function CCI() { parent::Controller(); } function index() { $this->load->view('login'); } function test() { echo "Testing Data"; }
}
/ * End of login.php file / / Location :./system/application/controllers/cci.php * /
class Welcome extends Controller {
function Welcome() { parent::Controller(); } function index() { $this->load->view('welcome_message'); } function test() { echo "Testing Data"; }
}
/ * End of welcome.php file / / Location :./system/application/controllers/welcome.php * /
function php codeigniter view controller
student
source share