/ Published in: PHP
write this in your .htaccess
links are going to look like this
yourpage.de/yourVariableValue1/yourVariableValue2/
[NC] will remove the case sensitivity of your static words like "admin"
its going to work, even if you type
yourpage.de/adMIN
Expand |
Embed | Plain Text
RewriteEngine on RewriteRule ^admin/?$ admin.php [NC] RewriteRule ^admin/([^/.]+)/?$ admin.php?action=$1 [NC] RewriteRule ^([^/.]+)/?$ index.php?a=$1 [L] RewriteRule ^([^/.]+)/([^/.]+)/?$ index.php?a=$1&b=$2 [L] RewriteRule ^([^/.]+)/([^/.]+)/([^/.]+)/?$ index.php?a=$1&b=$2&c=$3 [L]
Comments
Subscribe to comments
You need to login to post a comment.

Real good stuff. I didn't use the admin part, but lines 1, 7, and 8 were great. Thanks.
RewriteEngine On RewriteRule ^([^/.]+)/?$ ?a=$1 [L] RewriteRule ^([^/.]+)/([^/.]+)/?$ ?a=$1&fancy=$2 [L]