RewriteRule problem adding extension
Posted on 2007-08-02
I currently have the following .htaccess file that mod.rewrites a query to something resembling a static URL:
RewriteRule ^([^.]+)$ profile.php?country=$1
This allows for campus information about Canada to appear as /about/campus/canada, but I'd like to add the PHP extension to the back of the URL. When I place .php in the RewriteRule, however, it doesn't work unless I add [QSA] to the end, but then all PHP files in that direct redirect to profile.php.
I am a novice at mod.rewrite, any help is appreciated.