I wanted to block direct access to mp3 files and I am using this code:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www\.)?localhost [NC]
RewriteCond %{HTTP_REFERER} !^http://(www\.)?localhost.*$ [NC]
RewriteRule \.(gif|jpg)$ - [F]
taken from this answer:
It is working exactly how I need BUT when I load my site from any mobile device, the mp3 files won't play.
Any ideas?
Thanks!