Greenguy's Board


Go Back   Greenguy's Board > Newbie Questions
Register FAQ Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
Old 2006-11-22, 07:46 AM   #4
jayeff
Just because I don't care doesn't mean I don't understand!
 
jayeff's Avatar
 
Join Date: Sep 2006
Posts: 95
Send a message via ICQ to jayeff
This does the same, but it allows some of the image searches to show results and includes a response to non-image hotlinking:
Code:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} .*jpg$|.*gif$|.*png$ [NC]
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http(s)?://([^@\/]+@)?([a-z0-9-]+\.)*yourdomain.com(:80)*(/.*)* [NC]
RewriteCond %{HTTP_REFERER} !google\. [NC]
RewriteCond %{HTTP_REFERER} !msn\. [NC]
RewriteCond %{HTTP_REFERER} !yahoo\. [NC]
RewriteCond %{HTTP_REFERER} !search\?q=cache [NC]
RewriteRule (.*) /hotlink.png [R]
RewriteCond %{REQUEST_FILENAME} !^.*jpg [NC]
RewriteCond %{REQUEST_FILENAME} !^.*gif [NC]
RewriteCond %{REQUEST_FILENAME} !^.*png [NC]
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http(s)?://([^@\/]+@)?([a-z0-9-]+\.)*yourdomain.com(:80)*(/.*)* [NC]
RewriteRule (.*) /somepage.php [R,L]
hotlink.png and somepage.php are assumed to be in the root directory in this example and it also intended to allow type-ins, javascript access etc. You can modify/remove the relevant lines as you wish...
jayeff is offline   Reply With Quote
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 07:49 AM.


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