Codeigniter not recognising controllers and methods after server move

Have moved a codeigniter application to a new server.

Had to update virtual hosts etc. to allow .htaccess file to work – initially got a page not found error.

Now, the application is loading the default welcome screen, regardless of what URL is accessed i.e.

Have used the following to see what class / method is being loaded:

<? echo $this->router->fetch_class();?>
<br /><br/>
<? echo $this->router->fetch_method();?>

and this shows:



(where I would expect ‘admin’ and ‘edit’)

Looking at a print_r of $_SERVER in the welcome file, I can see the following:

[QUERY_STRING] => /admin/edit/

Which to me suggests .htaccess is doing its job?

Any ideas what I’ve missed?


Source: .htaccess

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.