Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
11-27-2014, 04:49 PM | #1 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
.htaccess Help
I have files (jpg. mp4, mp3) on one domain that I want to share with another domain, but not have them hotlinked to any other place.
http://jimspics. com/files/testfile.mp3 I want to put .htaccess in http://jimspics. com/files/ To block hotlinks, but allow file to be pulled over to http://truebabes. com/ Thoughts, samples, suggestions? Thanks
__________________
http://TrueBabes.com/ |
11-27-2014, 05:31 PM | #2 |
Confirmed User
Industry Role:
Join Date: Jan 2012
Location: cyberspace
Posts: 790
|
See next post
|
11-27-2014, 05:39 PM | #3 |
Confirmed User
Industry Role:
Join Date: Jan 2012
Location: cyberspace
Posts: 790
|
And here is a htacess generator for ya Click on the Disable Hotlinking tab and generate away
.HTACCESS IP, Referrer, and Hotlink Banning Generator |
11-27-2014, 05:50 PM | #4 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
I did try that, and couple of others discussed there, but no luck yet.
Thanks
__________________
http://TrueBabes.com/ |
11-27-2014, 06:08 PM | #5 |
Confirmed User
Industry Role:
Join Date: Feb 2007
Posts: 6,904
|
master domain root:
Code:
RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www\.)?domain1.com.*$ [NC] RewriteCond %{HTTP_REFERER} !^http://(www\.)?domain1.com:80.*$ [NC] RewriteCond %{HTTP_REFERER} !^http://(www\.)?domain2.com.*$ [NC] RewriteCond %{HTTP_REFERER} !^http://(www\.)?domain2.com:80.*$ [NC] RewriteRule .*[Jj][Pp][Gg]$|.*[Gg][Ii][Ff]$ http://www.originaldomain/hotlinkimagefolder/hotlinkimage.jpg Code:
RewriteEngine on RewriteRule ^.*$ - |
11-27-2014, 06:09 PM | #6 |
Confirmed User
Industry Role:
Join Date: Feb 2007
Posts: 6,904
|
sorry, just seen you have movie files too. I can't remember which domains I have that in place, but will have a look tomorrow if no-one has been able to give you the fix. 1am here and I gotta hit the sack before I drop
|
11-27-2014, 06:14 PM | #7 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
Acording to this site it should work.
.HTACCESS IP, Referrer, and Hotlink Banning Generator But, doesn't. Frustrating.
__________________
http://TrueBabes.com/ |
11-27-2014, 06:15 PM | #8 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
Thanks, look forward to what you find.
__________________
http://TrueBabes.com/ |
11-27-2014, 08:50 PM | #9 |
Confirmed User
Industry Role:
Join Date: Jan 2012
Location: cyberspace
Posts: 790
|
Noticed you're on HG. Did you try this?
What is hot linking? How do I enable and disable hotlink protection? « HostGator.com Support Portal |
11-28-2014, 09:36 AM | #10 |
Confirmed User
Industry Role:
Join Date: Feb 2007
Posts: 6,904
|
back.. ok sorry mate I was tired and not quite with it - now I've got a clearer head, from memory you can't prevent hotlinking movie files unless you do some tech shit that I have zero idea about. The other thing I was thinking of was related to redirecting image hotlinking by google's image search to a specific html page (instead of just showing your hotlink image), rather than preventing hotlinking of movies. Sorry for the confusion.
It can be done, but way above my head, hopefully others can chime in. |
11-28-2014, 12:23 PM | #11 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
Ah, ok then. Thanks for the help. That answers my main question.
__________________
http://TrueBabes.com/ |
11-28-2014, 12:24 PM | #12 | |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
Quote:
__________________
http://TrueBabes.com/ |
|
11-28-2014, 04:32 PM | #13 |
Confirmed User
Industry Role:
Join Date: Jan 2012
Location: cyberspace
Posts: 790
|
How bout just limiting the entire directory to a referer?
Something like this Use .htaccess to allow access only from a single HTTP referrer |
11-28-2014, 06:42 PM | #14 |
So Fucking Banned
Join Date: Jul 2006
Posts: 342
|
maybe your .htaccess isnt active, check apache settings
|
11-28-2014, 08:12 PM | #15 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: Littleton, Colorado. USA
Posts: 558
|
Thanks guys. That link is interesting, and going to try that now.
And yes, htaccess is active (its working fine for normal password protected areas and all. Just trying to block linking of .mp4 videos
__________________
http://TrueBabes.com/ |
11-28-2014, 10:19 PM | #16 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
Htaccess - THE Ultimate .htaccess
Code:
RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www\.)?askapache\.com/.*$ [NC] RewriteRule \.(gif|jpg|swf|flv|png)$ http://www.askapache.com/feed.gif [R=302,L] This format is right but you will have to set paths and file types -- he missed JPG and jpeg JPEG if necessary? -- Apache is case sensitive if that has something to do with the pathing problem. Also, any space must be escaped %20... The UNIX rule for naming conventions should be followed if you don't want grief (been there done that before). If the access is to be restricted in a certain directory, try putting the .htaccess in that directory. Apache reads the .htaccess in each directory in the path to the file's location when it will GET the file. |
12-02-2014, 02:00 AM | #17 | |
Too lazy to set a custom title
Industry Role:
Join Date: Aug 2002
Posts: 54,920
|
Quote:
i make my urls expire so they cant be shared
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence. WP Tube Themes |
|