Welcome Guest, Not a member yet? Register   Sign In
Created a subfolder under controllers...
#1

[eluser]Unknown[/eluser]
I have created a subfolder under controllers i.e. "employment".
My controller class is:

Code:
<?php
  class Employment extends Controller{
    
      function index(){
        //$this->load->view("employment/index_view");
        $this->load->view('employment/index_view');
      }
  }
?>

M accessing using this url: "http://localhost/code_igniter/employment/"

This is throwing error,
Object not found!
#2

[eluser]Senthilguru[/eluser]
Hi,

just do this...

In your config folderthere will be a file routes.php in that just put this code

Code:
$route['employment']    = 'employment/employment/index';


then try http://localhost/code_igniter/employment/....it will work

have a nice day,

Thanks and regards,
senthilguru.e
Cogzidel Templates(www.cogzideltemplates.com)




Theme © iAndrew 2016 - Forum software by © MyBB