I have made a webpage to play some videos using html5 video player. I wouldn't like to allow users to download video files, all videos will be saved in .mp4 extension. Generally users couldn't download but if they have some knowledge about html programming will download easily by browsing the source code and copying the direct video URL. I tried the htaccess code below to prevent video files from being downloaded and it worked also BUT it seems as if it doesn't allow to play even in webpage where I want to play them.
Code I tried
<FilesMatch "\.(mp4)$">
Order deny,allow
Deny from all
Allow from localhost/t/v.php
</FilesMatch>
Here I want to allow to localhost/t/v.php only to access these videos and deny from anything else. But it seems to not be working.
localhostto127.0.0.1and see if that works? (I'm not sure if it matters, though.) - Amal Murali