Reputation: 510
I am trying to install codeIgniter and I have copied all of codeIgniter files to a folder called /backend
in http://www.mydomain.com
.
Now, http://www.mydomain.com/backend/index.php
shows the codeIgniter welcome page.
Then I created a main.php
in the /backend/controller
folder. But when I open http://www.mydomain.com/backend/index.php/main
, it shows No input file specified
.
After looking at this question, i pasted a .htaccess file with the following contents into the /backend
folder.
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
But the page http://www.mydomain.com/backend/index.php/main
still says No input file specified
.
Why is the .htaccess
not making any difference? I don't understand whats going on.
Upvotes: 0
Views: 4274
Reputation: 49817
RewriteEngine On
RewriteBase /backend
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /backend/index.php/$1 [L]
then browse to :
http://www.mydomain.com/backend/main
and not to:
http://www.mydomain.com/backend/index.php/main
be sure you removed index.php
in config/config.php
and you setted $config['uri_protocol'] = 'AUTO'; (try also other solutions here if still not working)
Upvotes: 2