Created
January 5, 2015 19:51
-
-
Save shrwnsan/8a0daa4becfc8f0048b3 to your computer and use it in GitHub Desktop.
To remove the .php extension from a PHP file for example yoursite.com/wallpaper.php to yoursite.com/wallpaper
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Removing Extensions | |
# Source http://alexcican.com/post/how-to-remove-php-html-htm-extensions-with-htaccess/ | |
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteRule ^([^\.]+)$ $1.php [NC,L] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment