Answer the question
In order to leave comments, you need to log in
How to set video playback endpoint in YouTube Player API?
In the settings of the constructor of the created player object, there is the END property, which specifies the end time of video playback in seconds.
player = new YT.Player('ID_плеера', {
height: '360',
width: '640',
videoId: 'M7lc1UVf-VE',
playerVars:
{
start: 60,
end: 120
},
events:
{
'onReady': onPlayerReady,
'onStateChange': onPlayerStateChange
}
})
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question