Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

mod_rewrite not working

Status
Not open for further replies.

kbc1

Programmer
Feb 23, 2007
5
GB
Hi all

Running locally on my machine, this mod_rewrite works perfectly...

------------------------------
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^(/)?$ [L]
RewriteRule ^blue(/)?$ [L]
RewriteRule ^green(/)?$ [L]

<FilesMatch "^(blue|green)">
ForceType application/x-httpd-php
</FilesMatch>
------------------------------

Basically when someone hits my domain, I redirect them to to mydomain.com/blue/home and blue is a PHP file with the extension removed to implement tidy URLS. This is working great locally but when I upload it to my live web server, the redirect does not occur and the address bar of the browser simply stays at mydomain.com/

Strange thing is, when I change the redirect to something like / it does infact redirect without any problems.

Can any one offer suggestions as to why the redirect is not working?

Thanks in advance
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top