Skip to main content
Known Participant
January 18, 2012
Question

Youtube AS3 Api without branding

  • January 18, 2012
  • 1 reply
  • 859 views

I am loading a youtube video inside a AS3 app, and want the youtube logo not to be visible. I have used modestbranding but still it shows the logo. Below is the code I am using.

Security.allowDomain("www.youtube.com")

 

                    var my_player:Object;

                    var my_loader:Loader = new Loader();

 

                    public function ytPlayer() {

 

                    my_loader.load(new URLRequest("http://www.youtube.com/apiplayer?version=3&modestbranding=1"));

 

                    my_loader.contentLoaderInfo.addEventListener(Event.INIT, onLoaderInit);

                    }

 

                    function onLoaderInit(e:Event):void{

                    addChild(my_loader);

                    my_player = my_loader.content;

                    my_player.addEventListener("onReady", onPlayerReady);

                    }

 

                    function onPlayerReady(e:Event):void{

                    my_player.setSize(640,360);

                    my_player.loadVideoById("_OBlgSz8sSM",0);

                    }

Please suggest.

Ayush

This topic has been closed for replies.

1 reply

January 18, 2012

for this u hav to customize the player and  hav to use the youtube api of as3