1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-04 02:09:22 +02:00

improve beacon

This commit is contained in:
Daniel 2021-08-02 16:35:16 -03:00
parent 0202e787bf
commit f4a961c393

View file

@ -459,6 +459,7 @@ function addViewBeacon() {
if (typeof mediaId !== 'undefined' && typeof playerCurrentTime !== 'undefined' && typeof seconds_watching_video !== 'undefined') {
console.log('addViewBeacon will be sent', mediaId, playerCurrentTime, seconds_watching_video);
var url = webSiteRootURL + 'objects/videoAddViewCount.json.php?PHPSESSID=' + PHPSESSID;
let data = new FormData();
data.append('id', mediaId);
data.append('currentTime', playerCurrentTime);