war59312
02-02-2006, 02:51 AM
Hello,
I am having a problem opening images in a new window which is created via javascript.
The problem is that I get a 403 error because my .htaccess file is blocking it from displaying the image correctly.
Here is example of what I use to display and open images in a new window when click:
<a href="javascript:void(0)" onclick="window.open('http://www.example.com/images/exampleBIG.png')">
<img src="http://www.example.com/images/exampleSmall.jpg" alt="Just An Example Image" /></a>
Here is the part of my .htaccess file that matters:
# Stop Leechers From Hotlinking Images And Files
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www.)?example.com(/)?.*$ [NC]
RewriteRule .*\.(torrent|iso|gif|jpe?g|avi|css|doc|mid|mov|mp3|mp4|mpg|pdf|pps|ppt|ra|ram|swf|wav|wma|xml|png|cab|7z|cmd|txt|log|rar|zip|exe|js|ex_|dll)$ - [F,NC]
Thanks a lot,
Will
I am having a problem opening images in a new window which is created via javascript.
The problem is that I get a 403 error because my .htaccess file is blocking it from displaying the image correctly.
Here is example of what I use to display and open images in a new window when click:
<a href="javascript:void(0)" onclick="window.open('http://www.example.com/images/exampleBIG.png')">
<img src="http://www.example.com/images/exampleSmall.jpg" alt="Just An Example Image" /></a>
Here is the part of my .htaccess file that matters:
# Stop Leechers From Hotlinking Images And Files
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www.)?example.com(/)?.*$ [NC]
RewriteRule .*\.(torrent|iso|gif|jpe?g|avi|css|doc|mid|mov|mp3|mp4|mpg|pdf|pps|ppt|ra|ram|swf|wav|wma|xml|png|cab|7z|cmd|txt|log|rar|zip|exe|js|ex_|dll)$ - [F,NC]
Thanks a lot,
Will
