How can I rewrite http://localhost/index.php?page=sample into http://localhost/page/sample.
The only code inside my htaccess is the rule to remove index.php on the url.
RewriteCond %{THE_REQUEST} \ /(.+/)?index\.(html?|php)(\?.*)?\ [NC]
RewriteRule ^(.+/)?index\.(html?|php)$ ./$1 [R=301,L]
RewriteRule ^([^/]*)/$ ./index.php?page=$1 [QSA,L]
I am looking for rewriting the part with the parameter.
Thanks!
The rule would be this: