I've looked through the YouTube JS API, but can't find a way to jump to a video in a playlist. (Mimicking the built-in navigation)
And if you're wondering why I'd want both, it's because I have a menu set up with additional information, and want to let the user click these links to jump between the videos.
You can write your own YouTube player script or use this one -- YouTube JavaScript API Player plus Playlist.
Related
I've just loaded video.js plugin on my wordpress site.
I would like to find out if it is possible to disable the links 'get video url' etc. I want to add videos from youtube but don't want users linking to the unlisted videos. The videos are for a course and I don't want them shared. only users on the course get access to the videos.
But, the YOUTUBE logo still needs to be active due to their terms and conditions.
Many thanks
I add videos to my site via the JavaScript YouTube API. It works well except that at the end of the video playback, there are several video choices that appear on my screen. I want to choose the video or videos that appear at the end of my video.
How can I do this?
I have a slider which allows video embeds ( currently by pasting in iframe code from youtube/vimeo etc). The problem I have is that the video needs to pause the slider when the user clicks the video play button and also pause the video when the slider moves to the next frame.
It seems that I will need to use the vimeo and youtube API's to get access to the information and control I want. I have looked through the API's and I think I can probably get this happening; however my problem is that from what I've seen so far the youtube API tends to work off the video ID, whereas the Vimeo API seems to work with iFrames, but I need to have a consistent input for end users in that I want to say "Paste the video ID here" OR "Paste the Iframe here" OR "Paste the video URL here" ... I don't want to have to ask them for an ID from youtube for one video and an Iframe from Vimeo for the next one.
I know how to manipulate the data to make the two consistent but I'd rather avoid that if at all possible. What is the best approach to get programatic access to Youtube and vimeo so that I can achieve access to play and pause and know whether a video is playing or not.
there is a small widget on https://github.com/dachcom-digital/jquery-video with which you can archive the things you're asking for.
You can ask the user for the video ID and render some HTML container. Then you apply the widget and can pause, play, etc. the videos with one consistent API.
Hope this helps.
I have a page that displays YouTube videos using the YouTube API. For each video I have a specific 30 second add video that I would like to play before the main video. Is there a way to do this through the YouTube API or plain javascript/jquery?
All you need to do is embed the ad first, then when it's done playing, hide it and show the main video.
First, detect when the ad is done playing with the Youtube API player.getPlayerState() function. This returns a zero when the video is ended.
Then, hide the embed with Javascript and show the main video.
I want to link a playlist with the <audio> element in HTML5, so that:
When one song in the list ends, the next song starts automatically
The user can switch to the next or previous song in the playlist
How can this be achieved through HTML5, JavaScript etc.? I'm using ASP.NET at the backend.
Also, can I give user the liberty to play any song from his/her playlist alongside the audio player?
My friend told me that it can be achieved by tweaking its DOM (Document Object Model). Please help how can it be achieved?
How about jQuery HTML5 Audio Player? http://www.jplayer.org/latest/demo-02/