HomeiOS Developmentjavascript - Hello, I made an expressjs app to play video recordsdata...

javascript – Hello, I made an expressjs app to play video recordsdata in browser however video looking for isn’t engaged on ios


So i made this app so i can play movies from my laptop on my telephone and that i made it begin the video from when i closed it. It is working superb on chrome (laptop) however on my telephone (iOS 16) it begins from the start and the search bar isn’t even working

  fetch("/progress", { keepalive: false })
      .then((response) => response.json())
      .then((json) => {
          for (var x = 0; x < playlist.size; x++) {
              if (playlist[x].identify === json.now_playing) {
                  vidNow = x;
                  vidPlay(vidNow, true);
                  video.currentTime = json.current_duration
                  vSeek.worth = json.current_duration
              }
          }
          if (vidNow == 0) vidPlay(0, true);
      }); 

 var vidStart = true,
      vidPlay = (idx, nostart) => {
          vidNow = idx;
          vidStart = nostart ? false : true;
          video.src = encodeURI(playlist[idx]["src"]);
          for (let i in playlist) {
              if (i == idx) {
                  playlist[i]["row"].classList.add("now");
              } else {
                  playlist[i]["row"].classList.take away("now");
              }
          }
      };```


RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments