
function writeSo(file) {
	var swfwidth = 433;
	var swfheight = 360;
	
	var filePath = file;
	
	var so = new SWFObject("tools/swf/vidPlayer.swf", "warmandscratchyVid", swfwidth, swfheight, "8", "#ffffff");
	    //this is to allow a target to open in a window besides _blank
	  so.addParam("allowScriptAccess", "always");
	   	//this makes the background transparent
	  //so.addParam("wmode", "transparent");
	  
	  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", filePath);
	    //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", xmlFile);
	  
	    //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", 386);
	  so.addVariable("flvHeight", 290);
	    //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", 386);
	  so.addVariable("controlHeight", 28);
	     //use this to add or subtract to the control area y position
		 //set it to 0 to use the default
	   so.addVariable("controlY", 5);
	  
	    //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", "true");
	  	 //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", "false");
	    //playlistControls is required - it must not be commented out
		 //if true, the prev/next controls for the playlist are active
		 //if false, there are no playlist controls
	  so.addVariable("playlistControls", "false");
	  
	  	 //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", "images/stilltest.jpg");
	    //playerbg is the background image behind the video area
	 	//to have no bg, comment this out
	  //so.addVariable("playerbg", "images/test.jpg");
	  //so.addVariable("offsetBgX", 20);
	  //so.addVariable("offsetBgY", 20);
	  so.addVariable("bgWidth", 200);
	  so.addVariable("bgHeight", 500);
	  
	
	 	//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", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/controlsBg.jpg");
	    //playImage is the image for the play button
	  so.addVariable("playImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/play_unselected.png");
	    //pauseImage is the image for the pause button
	  so.addVariable("pauseImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/pause_unselected.png");
	  
	  so.addVariable("playImageRO", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/play_selected.png");
	  so.addVariable("pauseImageRO", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/pause_selected.png");
	    //playX is for the X coord of the play/pause area in pixels
	  so.addVariable("playX", 20);
	    //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", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/thumb.jpg");
	    //loadedTrackImage is the image for the loaded scrub bar
	  so.addVariable("loadedTrackImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/loaded_track.jpg");
	    //trackImage is the image for the unloaded scrub bar
	  so.addVariable("trackImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/track.jpg"); 
	    //trackX is for the X coord of the track in pixels
	  so.addVariable("trackX", 42);
	  
	    //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", "false");
	  so.addVariable("duration", "false");
	    //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", 35);
	    //durationX is the X coord for the duration time
	  so.addVariable("durationX", 267);
	  
	    //set the start volume of the video
		//from 0 to 100  (you can set higher, but the volume becomes distorted)
	  so.addVariable("startVolume", 50);
	    //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", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/volume.png");
	    //volumeIconX is for the X coord of the volume Icon in pixels
	  so.addVariable("volumeIconX", 377);
	    //soundWavesImage is the image for the waves coming out of the speaker
	  so.addVariable("soundWavesImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/soundwaves.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", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/mute.png");
	    //volumeThumbImage is the image for the thumb on the scrubber bar
	  so.addVariable("volumeThumbImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/thumb.jpg");
	    //set volumeTrack to true/false to turn it on or off
	  so.addVariable("volumeTrack", "false");
	    //volumeTrackImage is the image for the scrubber bar
	  so.addVariable("volumeTrackImage", "http://i.cdn.turner.com/adultswim/music/warmandscratchy/tools/img/track.jpg");
	    //volumeTrackX is for the X coord of the volume track in pixels
	  so.addVariable("volumeTrackX", 390);
	    //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("innerPause", "images/innerpausetest.png");
	    //innerPlay is the image for the play icon on the inner controls
	  so.addVariable("innerPlay", "images/innerplaytest.png");
	  
	   //if playlistControls is turned on, these control the images being on that controls
	   so.addVariable("playlistAlign", "right");
	     //these put a number over each instance in the playlist control buttons
       so.addVariable("numbers", "false");
		 //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", "images/plctrlsbg.png");
	     //comment out the next 4 variables if you don't want a next/previous control area
	   //so.addVariable("playlistCtrlsPrev", "images/plctrlsprev.png");
	   //so.addVariable("playlistCtrlsPrevRO", "images/plctrlsprevro.png");
	   //so.addVariable("playlistCtrlsNext", "images/plctrlsnext.png");
	   //so.addVariable("playlistCtrlsNextRO", "images/plctrlsnextro.png");
	     //these 3 must not be commented out
	   so.addVariable("playlistCtrlsCurrent", "images/plctrlsselected.png");
	   so.addVariable("playlistCtrlsChange", "images/plctrlsselected.png");
	   so.addVariable("playlistCtrlsOther", "images/plctrlsunselected.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);
	   
		//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
		//for movieBorderColor - must use 0x000001 for a black movieBorderColor 
	   //so.addVariable("movieBorderColor", 0x000001);
	   so.addVariable("timeColor", 0xFFFFFF);
	   so.addVariable("durationColor", 0xFFFFFF);
	  	
	  so.write("as_sitevplayer_flashcontent");
}
