• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

htaccess redirect from images to page

IronWing

No Lifer
I'm trying to modify my .htaccess redirect in order to allow search engines to return results on an image search while redirecting direct image links to the hosting page.

The script I was using redirected direct links to an error image to prevent image leaching:

Code:
SetEnvIfNoCase Referer "^http://mysite.com/" local_ref=1 
SetEnvIfNoCase Referer "^http://www.mysite.com/" local_ref=1 
<FilesMatch ".(gif|GIF|jpg|JPG|jpeg|png)"> 
Order Allow,Deny 
Allow from env=local_ref 
</FilesMatch> 
ErrorDocument 403 /redirect.gif

With this redirect neither google nor bing will return the images in an image search. The behavior I'm looking for is similar to Flickr's where the images are searchable but direct links to image files take the browser to a webpage instead.
 
Back
Top