fred august
fred august

Reputation: 1107

Play Youtube video from Flex app

I was wondering if anyone had any advice on what the best way to embed a youtube player inside a flex app is. I've looked around and it seems that one can

Would love to hear any thoughts from those of you out there that have done this in the past.

thank you!

Upvotes: 2

Views: 2502

Answers (3)

Joseph Orlando
Joseph Orlando

Reputation: 183

SWF-Loader cross-domain exceptions, add the following line to your code, BEFORE the player gets initialized.

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

Upvotes: 1

fred august
fred august

Reputation: 1107

Ok, after trying a variety of things, I've come to the conclusion that the Youtube API is probably the best way to go, but it doesn't work very well, at least it seems to have all sorts of issues in Flex 4 (see for instance http://groups.google.com/group/youtube-api-gdata/browse_thread/thread/f8e61440e5f1a21c/9ed01ed5fd6eb71b). The interesting thing is that the serious security errors seem to happen only if you move the mouse pointer over the Application stage. So if you can stomach to cover your whole application with something (at least a rect wrapped in a group) you should be ok. Ugly as hell, but that seems to be the only way I can find to make this work.

Upvotes: 0

Timofei Davydik
Timofei Davydik

Reputation: 7294

I think, the most convenient way is using youtube api. Check this turotial.

Upvotes: 1

Related Questions