user434885 user434885 - 18 days ago 5
PHP Question

How to change .php extension of website pages?

I have a website running on PHP. I want to remove the

suffix from all of my webpages in such way that the user doesn't get to know what server side language is running.

How do I edit the displayed address in the address bar to not show the


With mod_rewrite in .htaccess:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.php [NC,L]