How to add .php extension using .htaccess url rewriting?
问题 I have set up .htaccess file on my website which display SLUG text as page name in URL but without extension. e.g. Real url is www.mywebsite.com/page.php?page=about-us Then it loads on below url through url rewriting www.mywebsite.com/about-us Below is my .htaccess file code Options +FollowSymlinks RewriteEngine On RewriteCond %{REQUEST_URI} !^.*(images/|\.js|\.css).*$ [NC] RewriteRule ^([a-zA-Z0-9_-]+)$ /page.php?page=$1 Now I want to show the .php extension on all pages, so that the urls