Youtube video API using playerVars: { 'rel': 0 } for removing but it not working -


i try remove suggested video youtube player, using code given below still no luck.
have try find solution searching site can't able find solution. please me.

  function onyoutubeiframeapiready() {     player = new yt.player('player', {       height: '390',       width: '640',       playervars: {               'autoplay':       1,              'controls':       1,               'rel':            0,              'showinfo':       0,              'modestbranding': 1,              'autohide':       1,              'enablejsapi':    1,              'html5':          1       },       videoid: '<?php echo youtube_id_from_url(get_post_meta(get_the_id(),"mvyt_url",true)); ?>',       events: {         'onready': onplayerready,         'onstatechange': onplayerstatechange       }     });   } 

i have try remove related video video , not work me . try , 'rel':0, rel:'0', 'rel':'0' , no luck. try html5 : 1

please me!

i found placing rel=0 both in src of iframe in playervars worked, e.g.

<iframe id="hero_video_player" type="text/html" width="100%" height="100%" src="http://www.youtube.com/embed/qrekp9oijwi?rel=0&enablejsapi=1&origin=http://this.deakin.edu.au&showinfo=0" frameborder="0"></iframe> 

and:

var player;       function onyoutubeiframeapiready() {         player = new yt.player('hero_video_player', {             playervars: {                 'rel': 0             },             events: {                 'onready': onplayerready,                 'onstatechange': onplayerstatechange             }         });       } 

hope helps.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -