123.com i hosted files and abc.com is scripts site (this run my site)
In abc.com i have a script call download.php. This scripts will get the download link from database and display to download.
Now, I want deny all access to file at 123.com if the referrer is empty or is not abc.com and only accepted download (http) if referrer is 123.com
Then, i use this code:
- Code: Select all
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{HTTP_REFERER} .
RewriteCond %{HTTP_REFERER} !^http://(www\.)?123\.com [NC]
RewriteRule \.mp3$ - [F]
But it doesnt work.
It display 500 error.
Do you have any other option about this?
PS: my site run on linux host server and accepted mod rewrite with no limited anything