Welcome Guest, Not a member yet? Register   Sign In
mod rewrite question
#1

[eluser]modano[/eluser]
Hello,

I currently use the code found http://ellislab.com/codeigniter/user-gui.../urls.html here to make the urls more search engine friendly:

Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

My dilema is now that i want to force www to be removed from the url.
so if someone enters www.domain.com it will go straight to domain.com as well.

this is what i got, but this code and the one above seem to interfere with each other:
Code:
RewriteCond %{HTTP_HOST} ^www.domain.com$ [NC]
RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L]


grateful for any help!
#2

[eluser]modano[/eluser]
truly sorry, there was an error in my config.php file that caused the problem, not the htaccess.
please delete thread.




Theme © iAndrew 2016 - Forum software by © MyBB