Greenguy's Board

Greenguy's Board (http://www.greenguysboard.com/board/index.php)
-   General Business Knowledge (http://www.greenguysboard.com/board/forumdisplay.php?f=10)
-   -   I need an anti-hotlinking htaccess for WMVs (http://www.greenguysboard.com/board/showthread.php?t=13028)

Cleo 2004-11-10 04:21 PM

Quote:

Originally posted by JenC
I don't mind if it's not blocking Macintosh
It is not that it isn't blocking Macs it is blocking all Macs so they get an error that makes no sense when they click to watch the movie. Did I mention that all Cleo's Links reviewers are on Macs.

Over at the paysite that I manage for some strange reason we have more then the usual 4% on Macs, around 9%, not sure why. Anyway it was enough that we either had to stop using Strongbox or stop using WMVs.

Has anyone checked to see if the script works correctly with non IE browsers on Windows like Firefox?

JenC 2004-11-13 01:01 AM

Well it's not for my paysites, movie hosted galleries or free sites so I'm not concerned if Mac users are blocked. It won't affect any income.

badmuffy 2009-07-12 12:42 PM

Quote:

Originally Posted by stev0 (Post 99632)
This is what I use and it works with my wmv files...

.htaccess file

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://([a-z0-9-]+\.)*yourdomain.com(:80)*/ [NC]
RewriteCond %{HTTP_REFERER} !^http://([a-z0-9-]+\.)*anyotherreferingdomain.com(:80)*/ [NC]
RewriteCond %{HTTP_COOKIE} !(^|(.+;)*)id=valid(;.*|$)
RewriteRule /* http://www.picz.ca/notice.html [R,L] )


Then here's the trick to get it working with wmv's or any file for that matter.

Put this in the head of the html file that your visitors will see (with the videos on it).




That javascript will make a cookie (which is one of the rewritecond's in the htaccess file). So even though the wmv file doesnt show a referal, the surfer that was at that page will have that cookie and therfore can download the wmv file.


I saw this thread and am trying to implement this system of using a cookie to protect my mgp galleries, along with the .htaccess code. But it doesn't seem to be working. Has anyone used this successfully for mgp's and if so is it still worth trying this I thought tgp owners don't allow cookies anymore? (If you can't already tell I am a noob) : D


All times are GMT -4. The time now is 09:23 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
© Greenguy Marketing Inc