0

A couple of days i found an issue that my jquery wasn't responding on ios devices. Now i found what the problem was. It was a perfect working code. Now i thought i will not include this on mobile so i used this code

 This is the code:
   if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) === false ) {
    var muziek = getCookie("Muziek");

      // Save progression when leaving window
       window.onbeforeunload = () => {
           var prog = $('#muziek audio')[0].currentTime;
           console.log("current time = ", prog);
           sessionStorage.setItem('audioProgression', prog);
           };
       }

I test this on the google element inspector on the different sizes and it worked. But on my ipad it still doesn't, is there a way i can use this code to run and not block the jquery on my ios device? I do not need the music in the ios devices or other mobile/tablet devices. But i still need it on my computer browser. Does anybody know a way i can solve this?

Kind regards Dylan

0 Answers0