![]() |
![]() |
![]() |
||||
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 |
![]() |
#1 |
Confirmed User
Industry Role:
Join Date: Jan 2011
Location: Somewhere in Germany
Posts: 817
|
Prevent hotlinking with htaccess doesn't work
Hey guys.
A bunch of sites hotlink my media, so I wanted to prevent it with some htaccess code. I use wordpress, so there is a bunch of other stuff in the file. I only post the stuff I added: Code:
RewriteEngine On RewriteCond %{HTTP_REFERER} ^http://(www\.)?website1\.com(/.*)*$ [NC,OR] RewriteCond %{HTTP_REFERER} ^http://(www\.)?website2\.com(/.*)*$ [NC,OR] RewriteCond %{HTTP_REFERER} ^http://(www\.)?website3\.com(/.*)*$ [NC,OR] RewriteRule \.(jpeg|JPEG|jpe|JPE|jpg|JPG|gif|GIF|png|PNG|mng|MNG)$ - [F]
__________________
I know, my english is bad. But your german might be even worse ![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Confirmed User
Industry Role:
Join Date: Jun 2013
Location: Canada
Posts: 184
|
cache? maybe?
__________________
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Confirmed User
Join Date: Jun 2001
Location: swiss alps
Posts: 205
|
nginx maybe?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 | |
feeding the wolves
Industry Role:
Join Date: Aug 2012
Location: between sand and stars in Jamaica
Posts: 6,224
|
Quote:
hope that helps
__________________
throwing molotav cocktails at the precinct |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
Anti Communist
Industry Role:
Join Date: Nov 2003
Location: Null
Posts: 29,750
|
Link Hotten!
__________________
My mother said, to get things done You'd better not mess with Major Tom |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Friends of Venus founder
Industry Role:
Join Date: Jul 2010
Posts: 1,964
|
https perhaps instead of http?
__________________
Email: freedom6995 . protonmail.com |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
bored
Industry Role:
Join Date: Aug 2003
Location: Metaverse
Posts: 4,675
|
more of a !not instead of do. i dont think you want to update your htaccess every time a new asshole starts hotlinking. if the ref is NOT your site, redirect.
https://help.dreamhost.com/hc/en-us/...ge-hotlinking- and watch those mng files ![]() #
__________________
# ![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |