0

Possible Duplicate:
redirect *.php to *.html

My URL is index-main.html and it is redirecting to index-main.php, only index-main.html is showing on the address bar. My .htaccess file is:

<IfModule mod_rewrite.c>
   Options +FollowSymLinks
   RewriteEngine on
   RewriteRule index-main.html index-main.php
</IfModule>

But if I am calling index-main.php on the address bar, it is also working (the page displays), but the URL is not changing.

I want my URL to be index-main.html on the address bar. If i type index-main.php in the address bar, it should redirect to index-main.html, the URL should change.

  • it doesn't really matter what you call it... it is displaying the same thing. is there a reason why you have the rewriterule on? – au_stan Aug 17 '12 at 12:56

1 Answers1

-1

You can rename your file:

mv index-main.php index-main.html 

Then add to your .htaccess

AddHandler application/x-httpd-php .html

And should work without rewrite_mod

klocek
  • 562
  • 5
  • 11