0
RewriteEngine on
RewriteCond $1 !^(index\.php|resources|dms|robots\.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L,QSA] 

I have two sites both of which are developed in Codeigniter.One site is placed on the root folder and another one is in the subfolder.My problem is due to the .htaccess placed on the root folder. Above provided htaccess code is currently placed on my root.Now what I want is to set up a new codeigniter site as a subdomain named as 'dms' but I am getting Codeigniter's 404 error after placing all my code on my subdomain folder and trying to access any controller in the subdomain.

What changes should I make in the htaccess file

user1163513
  • 4,087
  • 7
  • 24
  • 25

1 Answers1

0

The easiest thing to do it to create a second DOCROOT/dms/.htaccess (assuming this is the folder mapped onto your dms subdomain with its own set of rules. This (and not DOCROOT/.htaccess) will be used for the subdomain requests.

See the Q&A Tips for debugging .htaccess rewrite rules for further explanation. :-)

Community
  • 1
  • 1
TerryE
  • 10,724
  • 5
  • 26
  • 48