4

I want a second website in my domain inside the folder test

www.mydomian.com/test

Apache server running on linux.

But when I load it in my navigator styles, images, helpers can't be found.

My htaccess is like this:

RewriteEngine On

RewriteBase /test

RewriteCond %{REQUEST_URI} ^system.*
RewriteCond $1 !^(index\.php|images|robots\.txt)


RewriteCond %{REQUEST_URI} ^application.*
RewriteRule ^(.*)$ /test/index.php?/$1 [L]


RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]

Thank you in advance

I have tried what you said, placing the htaccess file you gave me in the test folder and the other one in the root directory, it didn't work.

Other options?

user960894
  • 39
  • 1
  • 3
  • So your running a CodeIgniter webiste on your www.domain.com and you want a second inside www.domain.com/test? – Malachi Sep 23 '11 at 10:26

1 Answers1

4

Try adding a .htaccess file into your test folder instead.

I use this .htaccess content:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?/$1 [L]

In the folder test I would place another .htaccess, with almost the same content:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /test/index.php?/$1 [L]
Repox
  • 15,015
  • 8
  • 54
  • 79