66 976
Assignments Done
99,2%
Successfully Done
In November 2018

Answer to Question #22147 in AJAX | JavaScript | HTML | PHP for developer

Question #22147
I have a php based website which has video gallery with .mov format. so can i protect those videos from downloading while video playing?. is there any simple solution or it wil be fixed by just purchasing any video player to protect videos. i am using just <embed> for videos playing and those should be play in website and mobiles also....
Expert's answer
Using any players will always perform downloading video to a user device, such as a computer or mobiles. One option, when the user can't save downloaded video from cache - is to apply this code for every page what php script generates:
<?php
& header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
& header('Cache-Control: no-store, no-cache, must-revalidate');
& header('Cache-Control: post-check=0, pre-check=0', FALSE);
& header('Pragma: no-cache');
?>
This command sets flush the page cache immediately after using it. But it will not stop more experienced users, if the <embed> tag has an attribute the precise source of a video. To resolve this issue, scripts must set as source the dynamically changing address to the video, what must depend on the session in the browser.
This is best done using mod_rewrite - module for the Web server Apache, which allows you to modify the query address dynamically when it is loading. For more information, see the documentation. In my personal opinion, for maximum protection you also should use low quality or with a specific marketing content (such as the link to the
site) videos for viewing online with possible load of originals by certain rules.
For that you should, using php and ffmpeg, convert your video to less quality to be used for viewing. Moreover, these format videos will be better understood by mobile phones.
In conclusion, the use of most flash players does not protect your video from loading, but only gives the player a better view.

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions