function loadVideoPlayer() {
	var swfwidth = 498;
	var swfheight = 375;
	
	//var xmlFile = XML;
	
	var descColor = "0xaa4330";
	
	var movieID = "mymovie";
	
	var so = new SWFObject("tools/swf/videoPlayer.swf", movieID, swfwidth, swfheight, "8", "#00FF00");
			//this is to allow a target to open in a window besides _blank
		so.addParam("allowScriptAccess", "always");
		so.addParam("wmode", "transparent");
	   
		so.addVariable("omniAccount", "carnetglobaldev");
		so.addVariable("omniPageName", "A1");
		so.addVariable("omniPageURL", "http://www.adultswim.com/homePlayer2.swf");
		so.addVariable("omniMovieID", movieID);
		so.addVariable("omniVisitorNamespace", "cartoonnetwork");
		
		so.addVariable("swfHeight", swfheight);
		so.addVariable("swfWidth", swfwidth);
	   
			//flv loads in a single video file
			//if you use "flv" you have to comment out "xml"
		so.addVariable("flv", "http://ht.cdn.turner.com/adultswim/big/promos/carlcasting/carlcast_30_nobk.flv");
			//url defines a link for clicking on the video area of the flv player
			//to disable it, comment it out
		//so.addVariable("url", "test.html");
			//target defines where the url will open
			//choices are _self, _parent, _top, _blank
		so.addVariable("target", "_self");
	   
			//xml loads in a playlist with flvs and urls
			//if you use "xml", you have to comment out "flv"
		//so.addVariable("xml", "tools/xml/playlist.xml");
	   
			//flvWidth and flvHeight are required variables - don't comment them out
			//they define the width and height of the videoArea
			//To fill up the entire area set them to one pixel less than the swf size
			//to allow for the control area, set the height minus the height of the control area
			//never have the height more than 29 pixels difference from the swfheight if you are using the playlist controls
		so.addVariable("flvWidth", 498);
		so.addVariable("flvHeight", 375);
	   
			//the alignment for the video player in the swf window
			//must be defined: set to left, right or center
		so.addVariable("alignment", "left");
			//controlWidth and Height are required, but if you want the controls to not be streched, include them
			//usually set the width to the width of the flv and the height to around 30 or whatever you need
		so.addVariable("controlWidth", 378);
		so.addVariable("controlHeight", 24);
			//use this to add or subtract to the control area y position
			//set it to 0 to use the default
		so.addVariable("controlY", 0);
	   
			//autoplay is required - it must not be commented out
			//true automatically plays the video, false requires you a click before playing
		so.addVariable("autoplay", "true");
	   
			//loop is required - it must not be commented out
			//true sets the entire video and video list to replay
			//false will play through the video once and the entire playlist once
		so.addVariable("loop", "false");
	   
			//controls is required - it must not be commented out
			//if true, the main controls under the video area is visible
			//if false, there is no main control area
			//if controls == true, make sure to turn off innerControls & vice versa
		so.addVariable("controls", "false");
			//innerControls is required - it must not be commented out
			//if true, the play/pause is visible inside the video area
			//if false, there is no inner controls
			//if innerControls == true, make sure to turn off controls & vice versa 
		so.addVariable("innerControls", "true");
			//playlistControls is required - it must not be commented out
			//if false they are not active
			//if bottom, the prev/next controls are on the very bottom of the swf
			//if insidebottom, the controls are on the bottom of inside the flv area
			//if leftbottom, the controls are on the left of the video area towards the bottom
		so.addVariable("playlistControls", "false");
	   
			//descriptionAreaAlign is required - it must not be commented out
			//describes where the description area can be in relation to the player
			//if bottom, it's under the player
			//if lefttop, it's to the left and towards the top
		so.addVariable("descriptionAreaAlign", "lefttop");
	   
	   
			//still image is the image that displays in the video area if the autoplay is turned off
			//to have no still image, comment this out
		so.addVariable("stillImage", "tools/img/still.jpg");
			//playerbg is the background image behind the video area
			//to have no bg, comment this out
		//so.addVariable("playerbg", "images/bgtest.jpg");
		//so.addVariable("offsetBgX", 20);
		//so.addVariable("offsetBgY", 20);
		//so.addVariable("bgWidth", 200);
		//so.addVariable("bgHeight", 500);
	   
			//for videoBorderColor - must use 0x000001 for a black movieBorderColor 
		//so.addVariable("videoBorderColor", 0x000001);
	   
	 
			//the next six variables can be commented out if you want to use the default icons 
			//controlsbg is the bg for the entire main control area
		//so.addVariable("controlsbg", "tools/img/a1/controlsbg.jpg");
			//set this to true if you want to see the play/pause button
		//so.addVariable("playPause", "true");
			//playImage is the image for the play button
		//so.addVariable("playImage", "tools/img/a1/play_unselected.png");
			//pauseImage is the image for the pause button
		//so.addVariable("pauseImage", "tools/img/a1/pause_unselected.png");
	  
		//so.addVariable("playImageRO", "tools/img/a1/play_selected.png");
		//so.addVariable("pauseImageRO", "tools/img/a1/pause_selected.png");
			//playX is for the X coord of the play/pause area in pixels
		so.addVariable("playX", 20);
	  
			//set this to true if you want to see the scrubber track
		so.addVariable("track", "true");
			//thumbImage is the image for the scrubber thumb
			//if you use one of the next 3, you  have to use them all
		//so.addVariable("thumbImage", "tools/img/a1/thumb.jpg");
			//loadedTrackImage is the image for the loaded scrub bar
		//so.addVariable("loadedTrackImage", "tools/img/a1/loadedtrack.jpg");
			//trackImage is the image for the unloaded scrub bar
		//so.addVariable("trackImage", "tools/img/a1/track.jpg"); 
			//trackX is for the X coord of the track in pixels
		so.addVariable("trackX", 90);
	   
			//the following 6 are required parameters
			//set elapsed and/or to true if you want the elapsed time and false if not
		so.addVariable("elapsed", "true");
		so.addVariable("duration", "true");
			//timeFont is for the font face of the time displays
		so.addVariable("timeFont", "Verdana");
			//timeSize is for the size of the time displays font
		so.addVariable("timeSize", 10);
			//elapsedX is the X coord for the elapsed time
		so.addVariable("elapsedX", 45);
			//durationX is the X coord for the duration time
		so.addVariable("durationX", 275);
	  		//if controls is turned on and no images are set above these must not be commented out
			//these control the color of the default icons on the control areas
		so.addVariable("elapsedColor", 0xFF0F56);
		so.addVariable("durationColor", 0xF0F0FF);
	  
			//set the start volume of the video
			//from 0 to 100  (you can set higher, but the volume becomes distorted)
		so.addVariable("startVolume", 100);
			//if you add a volumeImage, you have to add them all or comment them all out
			//set volumeIcon to true/false to turn it on or off
		so.addVariable("volumeIcon", "true");
			//volumeImage is the image for the speaker icon
		//so.addVariable("volumeImage", "tools/img/a1/volumeimagetest.png");
			//volumeIconX is for the X coord of the volume Icon in pixels
		so.addVariable("volumeIconX", 357);
			//soundWavesImage is the image for the waves coming out of the speaker
		//so.addVariable("soundWavesImage", "tools/img/a1/soundwavesimagetest.png");
			//muteImage is the image for the mute icon
			//if one of these next 3 is commented out, all them have to be
		//so.addVariable("muteImage", "tools/img/a1/muteimagetest.png");
			//volumeThumbImage is the image for the thumb on the scrubber bar
		//so.addVariable("volumeThumbImage", "tools/img/a1/volumethumbtest.jpg");
			//set volumeTrack to true/false to turn it on or off
		so.addVariable("volumeTrack", "true");
			//volumeTrackImage is the image for the scrubber bar
		//so.addVariable("volumeTrackImage", "tools/img/a1/volumetracktest.jpg");
			//volumeTrackX is for the X coord of the volume track in pixels
		so.addVariable("volumeTrackX", 310);
	  
			//if innerControls is turned on, these must not be commented out
			//innerPause if the image for the pause icon on the inner controls
		so.addVariable("innerPauseImage", "tools/img/innerPause.png");
		so.addVariable("innerPauseROImage", "tools/img/innerPauseRO.png");
			//innerPlay is the image for the play icon on the inner controls
		so.addVariable("innerPlayImage", "tools/img/innerPlay.png");
		so.addVariable("innerPlayROImage", "tools/img/innerPlayRO.png");
	   
			//if playlistControls is turned on, these control the images being on that controls
			//use left center or right
		so.addVariable("playlistAlign", "center");
			//for setting the closeness of the playlist buttons
			//use close or far 
			//far can only use center aligned
		so.addVariable("playlistKerning", "far");
			//the space in pixels between the playlist controls
		so.addVariable("playlistButtonSpace", 10);
			//the space in pixels from the left
		so.addVariable("playlistOffsetX", 5);
	 
			//for playlistCtrlsBg, put in a transparent gif/png with the appropriate height & width if you don't want a bg to show up
		so.addVariable("playlistCtrlsBg", "tools/img/a1/controlsBg.png");
			//comment out the next 4 variables if you don't want a next/previous control area
		so.addVariable("playlistCtrlsPrev", "tools/img/a1/a1LeftArrow.png");
		so.addVariable("playlistCtrlsPrevRO", "tools/img/a1/a1LeftArrowRO.png");
		so.addVariable("playlistCtrlsNext", "tools/img/a1/a1RightArrow.png");
		so.addVariable("playlistCtrlsNextRO", "tools/img/a1/a1RightArrowRO.png");
			//these 3 must not be commented out
		so.addVariable("playlistSelected", "tools/img/a1/a1Active.png");
		so.addVariable("playlistUnselectedRO", "tools/img/a1/a1BoxRO.png");
		so.addVariable("playlistUnselected", "tools/img/a1/a1Box.png");
	   
			//if you want to select a set color for all of the text description on playlist,
			//use this to override the xml sheet.  Use this for if you have different stylesheets for the same page
			//comment out to not use it
		//so.addVariable("descColorOverride", descColor);
	   
		so.write("videoPlayer");
}
