New to .htaccess...
I want to make /schedules.php?sport=Football&team=Centerville into /schedules/football/centerville/
Printable View
New to .htaccess...
I want to make /schedules.php?sport=Football&team=Centerville into /schedules/football/centerville/
I think its better to throw all your request to index page and parse it using your server side scripts.
Use this htaccess code
RewriteEngine On
# Check if the file or directory actually exists – if it does we dont want to redirect
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# Pass the rewritten URL onto index.php with a $_GET['url'] parameter
RewriteRule ^(.*)$ index.php?url=$1 [PT,L]
I want to get rid of all the index.php, and queries...cleaning it up so that its domain.com/schedules/football/centerville and not domain.com/schedules.php?sport=Football&team=Centerville. We are going for "aesthetically pleasing."
try this one
http://www.tripkoto.com/2010/08/07/c...ccess-and-php/
hope it helps, Im not that good at grammar but its understandable.