where I work they use Flex, and I'm a newbie programmer! I work on another side of the business, but occasionally I need to do some light flex stuff. If anyone could help me out that would be great!
I am trying to make a simple widget that has 3 or 4 tabs and each tab displays a different youtube video. here is what i have so far...
Code:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
layout="absolute"
verticalAlign="top"
horizontalAlign="center"
creationComplete="Init();"
backgroundGradientAlphas="[1.0, 1.0]"
backgroundGradientColors="[#666666, #FFFFFF]"
viewSourceURL="srcview/index.html">
<mx:Script>
<![CDATA[
private function Init():void
{
var url:String = "http://youtube.googleapis.com/v/IMCdnPzYdTs"; //url extracted from embed code
Security.allowDomain(url); //allow domain
youtubevid.load(url); //load video
}
]]>
</mx:Script>
<mx:TabNavigator borderStyle="solid">
<mx:VBox label="Video 1" width="100%" height="100%" horizontalAlign="center" verticalAlign="top" verticalGap="0">
<mx:SWFLoader id="youtubevid" width="480" height="385"/>
</mx:VBox>
<mx:VBox label="Video 2" width="100%" height="100%" horizontalAlign="center" verticalAlign="top" verticalGap="0">
<mx:SWFLoader id="youtubevid2" width="480" height="385"/>
</mx:VBox>
<mx:VBox label="Video 3" width="100%" height="100%" horizontalAlign="center" verticalAlign="top" verticalGap="0">
<mx:SWFLoader id="youtubevid4" width="480" height="385"/>
</mx:VBox>
</mx:TabNavigator>
</mx:Application>