Greenguy's Board


Go Back   Greenguy's Board > General Business Knowledge
Register FAQ Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 2004-11-10, 04:21 PM   #51
Cleo
Subversive filth of the hedonistic decadent West
 
Cleo's Avatar
 
Join Date: Mar 2003
Location: Southeast Florida
Posts: 27,936
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?
__________________
Free Rides on Uber and Lyft
Uber Car: uberTzTerri
Lyft Car: TZ896289
Cleo is offline   Reply With Quote
Old 2004-11-13, 01:01 AM   #52
JenC
Stupid risks make life worth living
 
JenC's Avatar
 
Join Date: Aug 2003
Location: Eastern Seaboard
Posts: 387
Send a message via ICQ to JenC
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.
__________________
THIS IS MY SIG - CLICK IT.
JenC is offline   Reply With Quote
Old 2009-07-12, 12:42 PM   #53
badmuffy
Internet! Is that thing still around?
 
Join Date: Jul 2009
Posts: 1
Quote:
Originally Posted by stev0 View Post
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).

<SCRIPT LANGUAGE="javascript">
// Calculate the expiration date
var expires = new Date ();
expires.setTime(expires.getTime() + 24 * 60 * 60 * 1000);
document.cookie = "id=valid; path=/" + "; expires=" + expires.toGMTString();
</SCRIPT>


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
badmuffy is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:29 PM.


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