Open Tech Support
Open Tech Support Archives
Back to HomeCommunityReviewsGuidesDownloadsTech LinksMarketplaceContact Us
 »  SITE NAVIGATION
»  OTS Home
»  OTS Forums
»  OTS Archives

»  About our site
»  Search our site
»  Support our site

»  What is this site?
»  Who are we?
 
 
 »  ADVERTISMENT
 
  Pages: 1

Direct linking code

(Click here to view the original thread with full colors/images)


Posted by: Teresa

i tried puting a code to stop direct linking, and so far it's not working.

this is the code i have:

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?taste-like-rain.net/awards(/)?.*$ [NC]
RewriteRule .*\.(gif|jpe?g|png|bmp)$ [F,NC]


can somebody please help me?

-thanks



Posted by: Canis Lupus

Hmmm, try this on your .htaccess file:

Code:
order allow,deny
allow from all


RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://taste-like-rain.net/awards$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.taste-like-rain.net/awards$      [NC]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp)$ - [F,NC]


And make sure your server has mod_rewrite installed/enabled.



Posted by: Teresa

it still didn't work.

how can i tell if the mod_rewrite is installed/enabled?



Posted by: Canis Lupus

Quote:

Originally Posted by Teresa
how can i tell if the mod_rewrite is installed/enabled?

Is it a shared server or a dedicated server? Anyway, fire up notepad and put this in:

Code:
<?php
phpinfo();
?>

Save it as phpinfo.php and upload it to your site... enter the location of that file in your browser and scroll down to the apache section, and check if mod_rewrite is in your Loaded Modules column. It should be standard on apache servers, but if it's a shared hosting account, they might not have it there.



 
Copyright 2000-2008 Open Tech Support.  All Rights Reserved.  Site Design and Development by Tolitz Rosel.