Hi folks, Could someone, please, help me with the following: in my .htaccess I would like to rewrite all URL-s ending on ".html/any_characters" to ".html" Your help is greatly appreciated.
May need to see a link but try RewriteRule ^(.*)\.html(.*)$ $1.html [R=301, L] Not entirely sure if that is going to work though. hope that helps, Nigel
RewriteRule ^(.*)\.html(.*)$ $1.html [R=301, L] Code (markup): returns "500" Internal Server Error RewriteRule ^/?(.+)\.html/(.+)$ /$1.html [L] Code (markup): no changes
If you're going to rewrite "/$var.html/$any" into "/$var.html" there maybe a conflict on your .htaccess file. Or if you're using such as a free web host try to wait a minute for your web server.
Make sure there is RewriteEngine on Code (markup): on your htaccess. How about the other .htaccess file from different directory.