Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Youtube videos not playing on standalone Safari browser iOS 8

I have a very strange problem with an embedded youtube player on a web app, I am working on. The web app is "mobile capable" so when saved on a user homescreen, it opens up in a chromeless safari browser.



So here is my issue:



The YouTube player is embedded on one of the pages in the web app using an iframe, and when the "play" button is clicked and the app is open in the chromeless safari window, the video loads forever and never plays....however when this scenario is replicated in the regular safari browser everything works fine.



This started happening only after the iOS 8 update. This is happening on an iPhone 5 running iOS 8, and it previously worked fine on the same iPhone 5 under iOS 7. Additionally, I tested the app on an iPhone 5c running iOS 7, and an iPad Air running iOS 7 and everything works fine.



Side Note: I even changed the implementation to embed using an object instead of an iframe, and the same problem occurs with either one.

iPhone 5, iOS 8

Posted on Sep 24, 2014 11:24 AM

Reply
51 replies

Oct 10, 2014 9:04 PM in response to ludovicyu

This is a significant problem if Apple is going to allow developers to deploy web applications that can be saved as a chromless web app.


My question is, who is responsible for fixing this issue? is this something YouTube needs to address? or Apple?


looking at the error console I am not able to troubleshoot the issue as I am not able to see any errors firing when attempting to play an embedded player.


i believe this issue may also be effecting other html5 code as well on other sites.


Apple PLEASE respond.

Oct 22, 2014 9:32 AM in response to ludovicyu

Not sure if this will help anybody, but we found a script where you can detect if the user is viewing in 'web app mode' using javascript and then include / don't include your youtube videos accordingly


<script>

if (window.navigator.standalone == true) {

document.write('');

}else{

document.write('<iframe class="video" src="//www.youtube.com/embed/video_ID" frameborder="0" allowfullscreen></iframe>');

}

</script>


Seems to work pretty well in the interim until Apple fix this clear bug.

Youtube videos not playing on standalone Safari browser iOS 8

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.