.htaccess: Redirect Hotlink Flash --> Site with embed Flash

Posted by user5571 on Pro Webmasters See other posts from Pro Webmasters or by user5571
Published on 2011-02-21T22:06:44Z Indexed on 2011/02/21 23:34 UTC
Read the original article Hit count: 832

Filed under:
|
|
|
|

Hello, I have some .php sites that embeds .swf files. These .swf files are now linked to by some other guys. And I don't want them to simply open the SWF, I want them to force being redirect to the page where the flash is embed.

Data: Site: www.example.com/1 (www.example.com/2, www.example.com/3 and so on) Flash: www.example.com/flash/flash_NUMBER.swf

So for www.example.com/1:

Site: www.example.com/1 Flash: www.example.com/flash/flash_1.swf

I now want to redirect the user who types "www.example.com/flash/flash_1.swf" into his URL to be redirect to www.example.com/1. The Problem I have that the flash needs to be still accesseable via www.example.com/1 <-- I don't get that working (the Flash is embed into that page).

The tool I would like to use for this is the .htaccess & RewriteRule. I hope someone can help me out.

© Pro Webmasters or respective owner

Related posts about htaccess

Related posts about flash