Prindol

DESIGN, HTML5, CSS3, DOM, Jquery, JSON, Actionscript2/3, Linux, IIS

You are not logged in.

#1 2012-06-27 23:21:26

skydown
Administrator
Registered: 2011-07-25
Posts: 315

[AS2] import youtube

 this.createEmptyMovieClip(“video_mc”, 10000);this.video_mc.loadMovie(“http://www.youtube.com/v/b694exl_oZo”); //Put the URL for your video in this line 
 Security.allowDomain("www.youtube.com");var videoPlayer:Object;var loader:Loader = new Loader();     loader.contentLoaderInfo.addEventListener(Event.INIT, onLoaderInit);     loader.load(new URLRequest("http://www.youtube.com/apiplayer?version=3"));function onLoaderInit(event:Event):void {      addChild(loader);     loader.content.addEventListener("onReady", onPlayerReady); }function onPlayerReady(event:Event):void {     trace("Ready");     videoPlayer = loader.content;     videoPlayer.setSize(640, 385); //PUT THE DIMENSIONS OF YOUR VIDEO IN THIS LINE     videoPlayer.cueVideoByUrl("http://www.youtube.com/v/b694exl_oZo", 0);//PUT YOUR VIDEO URL IN THIS LINE} 

http://betaprogrammer.com/content/?p=228

Offline

Board footer

Powered by FluxBB