Another simple modification to your PlayTube core would be setting the autoplay checkbox defaulted to checked. This way anyone that visits your website will automatically be shown the next recommended video. If they choose to opt out by unchecking the Autoplay box, then they will still get the cookie stored so autoplay is no longer enabled for that visitor. This works for both logged in and unregistered members.
Find in /sources/watch/content.php
1 2 3 4 5 6 7 8 9 |
if (!empty($_SESSION['autoplay'])) { if ($_SESSION['autoplay'] == 2) { $checked = 'checked'; } } |
Add this above the previous code
1 2 3 4 5 |
if (empty($_SESSION['autoplay'])) { $checked = 'checked'; } |
Have a request? Feel free to reach out to me.