Printable Version of Topic

Click here to view this topic in its original format

HTMLHelp Forums _ Web Server Configuration _ Redirecting extension help

Posted by: bildss Jun 7 2015, 02:16 PM

I want to redirect all index default .asp .aspx .pl .php etc extension to already have a code that seems to work but dont know if its right or gonna cause issues.

RewriteCond %{THE_REQUEST} ^[A-Z]+\ /([^/]+/)*default(\.[a-z0-9]+)?[^\ ]*\ HTTP/
RewriteRule ^(([^/]+/)*)default(\.[a-z0-9]+)?$$1 [R=301,L]

RewriteCond %{THE_REQUEST} ^[A-Z]+\ /([^/]+/)*index(\.[a-z0-9]+)?[^\ ]*\ HTTP/
RewriteRule ^(([^/]+/)*)index(\.[a-z0-9]+)?$$1 [R=301,L]

Can someone tell me if this code is good?

Powered by Invision Power Board (
© Invision Power Services (