Is there a way to close a video after it is complete from an iPhone? I have a quiz that requires them to watch a video, and a timer that starts after it completes, but on the mobile device it doesnt close automatically. I am currently using the YouTube JavaScript API.
Does the webkitExitFullScreen function help if bound to the ended property for the video: (assuming jQuery, but you can bind the event using addEventListener if you're not using jQuery)
$('#video').bind('ended', function(){
document.getElementById('video').webkitExitFullScreen();
});
You will probably want to wrap it in a test for iOS specifically, as I think it's a proprietary extension so you'll want to avoid errors on other browsers...
https://developer.apple.com/library/safari/documentation/AudioVideo/Reference/HTMLVideoElementClassReference/HTMLVideoElement/HTMLVideoElement.html#//apple_ref/javascript/instm/HTMLVideoElement/webkitExitFullscreen
Related
I am currently working on flutter app that main core feature is video calling.
I am using Agora.Io SDK for video calling. and I also implement FCM for Video call acceptance Screen and that is working fine but my question is how to handle that video call when the user receives an actual call and resume that call when the call is finished (like resume and pause )
how should I put that video call on hold and continue?
any help would be appreciated
You can use pauseAudio() and resumeAudio() function for your use case. You can find detailed description about these functions over here: https://github.com/Meherdeep/agora-flutter-documentation
I've build an agent that uses dialogflow and fulfillment with the actions-on-google library. In a certain intent, the fulfillment sends back a SimpleResponse, a MediaResponse and some Suggestions.
It works fine in the simulator, the audio file in the MediaResponse plays as expected.
When testing the agent in the Google Assistant app on my iPhone however, the audio file isn't playing. There isn't a play/pause button but shows a loading/buffering gif instead. When I click on the loading gif the audio file starts playing and the start/pause button appears.
I don't think this is expected behaviour, is this a bug on Google's end or am I missing something here? Is there even a way to default autoplay the audiofile without the user having to push the icon?
As it turns out, this is a bug in Actions on Google and they are working on it.
Media responses are supported out of the box only on Android and Google home devices. You must check for the surface capabilities before trying to play the audio. You can check https://developers.google.com/actions/assistant/responses#media_responses for more options and suggestions.
What I would suggest is if you are playing small audio clips in between text/speech data, then use SSML. Check audio tag in the link https://developers.google.com/actions/reference/ssml
We are developing a mobile application (using ionic framework, jquery) and thinking to let our users to share videos from vimeo, youtube etc. in this case we are integrating vimeo video link in iframe. Below are challenges:
Not able to play vimeo videos inline in our application:
on iPhone device when we play vimeo video from our ionic application it opens in a native video player, on the contrary we want to play it inline in our application itself
in case of Youtube video its supported and works well. They have provide Playsinline property to support it.
As per vimeo developers documentation, we have not found any similar video player property to allow inline video rendering
Is there any workaround that you suggest to play vimeo video inline inside application?
Play, seek & load progress events are not supported in mobile application
As per your developers page, play, seek, load progress etc events are not supported in mobile application
Is there any workaround to enable these events on our mobile application
Yes, I know there are limitations that vimeo has declared but can someone provide me if there are any workarounds? Your response to our queries is very much important for us.
Reference:
https://developers.google.com/youtube/player_parameters
https://developer.vimeo.com/player/js-api#event-compatibility
try adding background=1 to your embed code
<iframe id="player1" src="https://player.vimeo.com/video/[video id]?api=1&player_id=player1&background=1" width="630" height="354" frameborder="0"></iframe>
This wil not work in browsers which revert to the flashplayer.
I don't know if you'll have javascript API functionallity.
This will remove all controls aswell. What I've read, it's still in an experimental fase, but hope it works for you.
Is this possible to make sound beep at mobiles like iPhone.....or play native sound....I testing phoneGap.js but it don't works to me......I want to make alert sound when new message arrives to end user at mobile...
javascript sound.play worked for me last time i made an html/5/jss app, which if your using phonegap, must be.... app, was a simple html/js game.
I'm a newbie to cocoa programing on iPhone.
My client has a website that plays YouTube videos. Once a video is finished playing, it will automatically play the next one. This is done by using the YouTube API and swfobject.
After some research, I was told that Safari on iPhone does not support flash. This make the current swfobject code not working on the iPhone browser.
As workaround, when the user clicked on an embedded player, iPhone will launch the YouTube app.
Is to possible to determine when the YouTube app has finished playing and has returned control back to browser?
You can use UIWebView to play videos from YouTube. You'll have to control those from your application though (start, stop, play next, etc).
Also In iOS you can register custom URI schemes and then redirect the browser (or UIWebView) back to your application. This is how many application do 3-legged OAuth for example (which requires a browser interaction). Which might require having a control over the server.
No, it is not possible to jump out of your App and then come back to it again. Once you leave your App, you are finished.
You'll need to stay in a UIWebView, or come up with another method of playing the YouTube videos from within your App.
-t