When I play videos on my website, I use the function provided below. I want the videos to start automatically, but I don't want them to repeat once they end. I tried changing the loop parameter to loop=0
, but unfortunately, it didn't work. Do I need to include any additional code to achieve this?
function ytplayer_render_player( )
{
swfobject.embedSWF
(
'http://www.youtube.com/apiplayer?video_id='+ ytplayer_playlist[ ytplayer_playitem ].videoid + '&enablejsapi=1&autoplay=1&loop=0&version=3&rel=0&fs=1&playerapiid=ytplayer',
'ytplayer',
'400',
'225',
'10',
null,
null,
{
allowScriptAccess: 'always',
allowFullScreen: 'true'
},
{
id: 'ytplayer'
}
);
}