Home › Forums › Newbie Helpdesk › Htaccess question on adult tube site
- This topic is empty.
-
AuthorPosts
-
erionGuest
I’d be grateful for any tips on this.
I have some sites hotlinking direct to video files in a folder. I’m moving the files to a new location and my own pages will reflect that.
I would like to put an htaccess in the folder so that when other sites hotlink to something.wmv or anotherthing.wmv what always plays is promo.wmv. Plus the same for flv and mov.
I know I can research on Google to find out how to do this (eventually) but just thought someone may already be doing it.
maxaffGuestI can hook you up with a good script, but it’s really not an htaccess issue as it requires cookies as well. I am not sure I know a pure htaccess way to protect vids. If anyone does maybe you want to use that way instead.
erionGuestIt’s not so much protect. I’m going to change the file location and I want anyone who tries to pull a file from the old location to get a particular promo video instead.
DOCGuestTry this:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://www.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.com$ [NC]
RewriteRule .*\.(mp3|mpeg|mpg|ram|rm|wma|wav|asx|wmv|avi|mov|zip|rar|exe)$ domainlinktoforwardto.com [R,NC]Replace domain.com with your domain name
Replace domainlinktoforwardto.com with where you want them to go.erionGuestThanks! I tried that and it does what I want.
-
AuthorPosts