I have a hand-coded .htaccess file with both hotlinking protection code in it and some other rewrite rules. When I uploaded it to my web server, I noticed that the hotlinking protection wouldn't work, although cpanel said hotlinking protection was enabled. Here's a portion of my .htaccess file:
When I went into the control panel and clicked on Disable Hotlinking, here's what cpanel did to my .htaccess file:Code:RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www\.)?napathon.net(/)?.*$ [NC] RewriteRule .*\.(gif|jpg|jpeg|bmp)$ http://www.napathon.net/images/nohotlink.gif [R,NC] RewriteRule ^AlbumID([0-9]+)\.html /TrackListRedirect.php?AlbumID=$1 [L]
Seems as though cpanel has a bug. Is there something that can be done about this? I'd appreciate some comments from cpanel staff about this issue. Thanks.Code:RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www\.)?napathon.net(/)?.*$ [NC] RewriteRule .*\.(gif|jpg|jpeg|bmp)$ http://www.napathon.net/images/nohotlink.gif [R,NC]http://www.napathon.net/TrackListRedirect.php?AlbumID=$1


LinkBack URL
About LinkBacks
Reply With Quote
FWIW, I had my ISP turn off cPanel's hotlinking protection so that option doesn't even show up on cPanel for me. That seems to have solved the problem. However, it would be much preferred if cPanel would play nicely with the code in .htaccess that I build myself.