Go Back  HTML Forums - Free Webmaster Forums and Help Forums > SERVER ADMINISTRATION > Linux Administration
User Name:
Password:
 

Reply
Thread Tools   Display Modes
  View First Unread
 
Old 08-31-2009, 09:21 AM
  #1
eventide
Veteran (Level 7)
 
eventide's Avatar
 
Join Date: Mar 2009
Location: Central Minnesota
Posts: 66
iTrader: (0)
eventide is an unknown quantity at this point
.htaccess: preventing hotlinking

In the root folder of my domain (public_html) I have the following in my htaccess file to prevent hotlinking:

Code:
# Block external sites from linking to images in my domain (Hotlinking)
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?eventidewebdesign.com(/)?.*$ [NC]
RewriteRule .*\.(gif|jpg|jpeg|bmp|png|tif|jpe)$ - [F,NC]
As you can see in my signature, the above code breaks the link to an image I use in forums.

How can I allow linking to images in a particular sub-folder with the above code set in an htaccess file in a higher-level folder?

Thanks for any help!
__________________
f u dn rd ths u cn gt a gd jb n prgrmmng

Eventide Web Design
eventide is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 08-31-2009, 09:31 AM
  #2
¥åßßå
Blonde Bimbo
 
¥åßßå's Avatar
 
Join Date: Jul 2004
Posts: 2,243
iTrader: (0)
¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all
Add this before your RewriteRule :

RewriteCond %{REQUEST_URI} !^/your_folder

¥
__________________
I may have opened the door, but you entered of your own free will

¥åßßå is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 08-31-2009, 09:56 AM
  #3
eventide
Veteran (Level 7)
 
eventide's Avatar
 
Join Date: Mar 2009
Location: Central Minnesota
Posts: 66
iTrader: (0)
eventide is an unknown quantity at this point
Ah! Of course - an exclusion line. Should've thought of that...

Thanks!
__________________
f u dn rd ths u cn gt a gd jb n prgrmmng

Eventide Web Design
eventide is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 08-31-2009, 09:58 AM
  #4
¥åßßå
Blonde Bimbo
 
¥åßßå's Avatar
 
Join Date: Jul 2004
Posts: 2,243
iTrader: (0)
¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all¥åßßå is a name known to all
No worries

¥
__________________
I may have opened the door, but you entered of your own free will

¥åßßå is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 09-27-2009, 09:47 PM
  #5
wch123j
Catapulted
 
Join Date: Sep 2009
Posts: 4
iTrader: (0)
wch123j is an unknown quantity at this point
Arrow How to Treat a Cold

Unfortunately, there is no cure for the common cold, however, most colds will go away in 3-7 days. Sometimes though, it may not. Treatment of a cold is therefore is limited to symptomatic support which can be effective in limiting complications and the duration a cold. The following steps are generally accepted means to make having a cold less uncomfortable.This article comes from medical database http://www.jiejiu8.cn
wch123j is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote

Reply
KEEP TABS
SPONSORS
 
Boxedart
 
 


 
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
  
 
 
 



 
  POSTING RULES
 
 
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Thread Tools
Display Modes

Forum Jump

 

All times are GMT -5. The time now is 01:19 PM.

   

Mascot team created by Drawshop.com

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

Server Monitoring by ENIACmonitor 0.01
HTMLforums.com © Big Resources, Inc. Web Design by BoxedArt.com
vRewrite 1.5 beta SEOed URLs completed by Tech Help Forum and Chalo Na.