Reputation: 786
I have a site that I have moved to a testing area on a different server. The URL is:
http://www.example.co.uk/clientarea/royston/the_team (This isn't a live site so the link won't actually work)
When the site was on the live server it would have been:
http://www.example.co.uk/the_team
I have a htaccess file that looks like this:
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
##Remove Trailing Slashes
RewriteRule ^(.+)/$ http://%{HTTP_HOST}/$1 [R=301,L]
##Ignore
RewriteCond %{REQUEST_URI} !^/admin
RewriteCond %{REQUEST_URI} !^/css
RewriteCond %{REQUEST_URI} !^/images
RewriteCond %{REQUEST_URI} !^/includes
RewriteCond %{REQUEST_URI} !^/internal
RewriteCond %{REQUEST_URI} !^/modules
RewriteCond %{REQUEST_URI} !^/scripts
##Remove .php from filename
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^([^.]+)$ /$1.php [L]
I need to know how to change the htaccess so that the URL will work on the test site.
Many thanks
Upvotes: 1
Views: 63
Reputation: 3949
Change theses lines :
RewriteBase /clientarea/royston/
and
RewriteRule ^([^.]+)$ /clientarea/royston/$1.php [L]
EDIT : You could also use your ReweireRule like this so you wont need to change it
RewriteRule ^([^.]+)$ $1.php [L]
Upvotes: 1