This post explains how to Hide .php extension with url rewriting using .htaccess file and also it will improve your Web projects security.
For rewriting the URL, you should create a .htaccess file in the root folder of your web directory. And have to put the following codes into htaccess file.
RewriteEngine on RewriteRule ^(.*)\$ $1.php [nc]
It will rewrite the index.php to index.html i.e when a URL like http://www.91weblessons.com/index.html is called in address bar it calls http://www.91weblessons.com/index.php. Here [nc] means not case sensitive.