-
.htaccess help please
I'm trying to make it so the following link:
http://www.somesite.com?city=somecity
will be instead re-written to:
http://www.somesite.com/somecity
The existing .htaccess file I have is below. This strips out the .php extension and resolves the http/www URL issue. This works fine.
Existing
Options +FollowSymLinks -MultiViews
RewriteEngine on
RewriteCond %{HTTP_HOST} ^somesite.com
RewriteRule (.*) http://www.somesite.com/$1 [R=301,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule ^index\.php$ http://www.somesite.com/ [R=301,L]
RewriteBase /
RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s([^.]+)\.php [NC]
RewriteRule ^ %1 [R,L,NC]
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^ %{REQUEST_URI}.php [L]
And this is what I'm adding at the end but it does absolutely nothing:
Addition
RewriteRule ^/city/([0-9]+)\ /www.somesite.com/city=$1
Does anyone have any thoughts as to why this isn't working?
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
|
Bookmarks