Chrisj Posted September 24, 2019 Share Posted September 24, 2019 The html5 player works successfully on my web page, but I’m wondering if there is a way to limit the video replays. Here’s the code: <video id="my-video1" controls autoplay style="width:100%; height:100%;" poster="{{THUMBNAIL}}" disablePictureInPicture controlsList="nodownload"> <?php if (!empty($pt->video_1080)) { ?> <source src="{{VIDEO_LOCATION_1080}}" type="{{VIDEO_TYPE}}" data-quality="1080p"> <?php } ?> <?php if (!empty($pt->video_720)) { ?> <source src="{{VIDEO_LOCATION_720}}" type="{{VIDEO_TYPE}}" data-quality="720p"> <?php } ?> <?php if (!empty($pt->video_480)) { ?> <source src="{{VIDEO_LOCATION_480}}" type="{{VIDEO_TYPE}}" data-quality="480p"> <?php } ?> <?php if (!empty($pt->video_360)) { ?> <source src="{{VIDEO_LOCATION_360}}" type="{{VIDEO_TYPE}}" data-quality="360p"> <?php } ?> <?php if (!empty($pt->video_240)) { ?> <source src="{{VIDEO_LOCATION_240}}" type="{{VIDEO_TYPE}}" data-quality="240p"> <?php } ?> Your browser does not support HTML5 video. </video> I look forward to any replies/assistance Quote Link to comment https://forums.phpfreaks.com/topic/309274-how-to-limit-replays-on-html5-player/ Share on other sites More sharing options...
requinix Posted September 24, 2019 Share Posted September 24, 2019 You can't prevent someone from replaying the video if it downloaded to their computer. Most you can do is prevent them from downloading the video a second time, which you would do by creating a one-time URL that allows you to know when the video was requested and when another attempt to download through that same URL should be blocked (which implies routing the video through a PHP script instead of giving direct access). Quote Link to comment https://forums.phpfreaks.com/topic/309274-how-to-limit-replays-on-html5-player/#findComment-1569937 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.