0

Hi I'm wondering if there is a way to embed online videos in my flash file. I know its possible to embed videos from youtube but I need from different website.

For now I need form http://www.dailymotion.com/ or maybe some other sites. Is there any universal AS or its different from site to site?

I would be happy if someone could help me with dailymotion videos?

Or can teach me how to do it and tell me what is important to modify for different sits.

Thanks.

I have this for youtube videos but I need to modify for daliymotion.com videos.

 import flash.display.Loader;
 import flash.net.URLRequest;
 import flash.events.Event;
 import flash.ui.MouseCursor;

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

 var player:Object;

 var loader:Loader = new Loader();
 loader.load(new URLRequest("http://www.youtube.com/apiplayer?version=3"));
 loader.contentLoaderInfo.addEventListener(Event.INIT, onInit);

 function onInit(e:Event):void{

addChild(loader);

player = loader.content;

player.addEventListener("onReady",onPlayerReady);

    }

    function onPlayerReady(e:Event):void{

player.setSize(640,360);

player.loadVideoById("NBRqUqilRfY",0);  

    }
Tilly
  • 427
  • 1
  • 4
  • 10

1 Answers1

1

To be able to embed Dailymotion's Player into your Flash app, You should use for the moment the old Flash API : http://www.dailymotion.com/pl/doc/api/player-deprecated/flash_api.

Check also Dailymotion Flash Player API

Community
  • 1
  • 1