Monday, June 6, 2011

URL Rewriting

Found a really nice and simple article on URL rewriting using .htaccess. Thought of sharing it :)
Here is it:-
http://www.sicanstudios.com/how-to-remove-php-html-htm-extensions-with-htaccess/

1 comment:

  1. Found this on Google, thought this information will be useful to the readers of this post.

    The explanation:-

    RewriteEngine on
    This line starts the mod_rewrite module
    RewriteCond %{REQUEST_FILENAME} !-d
    If the request is for a real directory (one that exists on the server), index.php isn't served.
    RewriteCond %{REQUEST_FILENAME} !-f
    If the request is for a file that exists already on the server, index.php isn't served.
    RewriteRule ^(.*)$ /index.php

    ReplyDelete