Friday, 13 September 2013

PHP/.htaccess - Redirect visitor when accessing page with .php extension

PHP/.htaccess - Redirect visitor when accessing page with .php extension

I want my visitors to get redirected when they access pages with .php
extension name. To make it a bit clearer:
I currently have .htaccess set to remove .php extension from URL in which
when visitor types in www.mysite.com/about/ it loads the
www.mysite.com/about.php content. I basically want the same thing happen
in reverse like:
When visitor enters www.mysite.com/about.php into the address bar, I want
to load the same content, but redirect/change the URL to
www.mysite.com/about/ and appear in the address bar.
Thanks in advanced! Paul G.

No comments:

Post a Comment