0
當前網址:mod_rewrite的URL
http://localhost/blog/profile.php?username=Username&page_type=following
我希望它是:
http://localhost/blog/profile/Username/following
當前的.htaccess:
RewriteEngine On
CheckCaseOnly On
CheckSpelling On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^profile/(.*)$ /blog/profile.php?username=$1&page_type=$2 [QSA,L]
是否可以這樣改寫呢?還是有更好的方法?