
function asf_embed()
{
	var str,src;
	var mPlayer = getCookie('cnet_newsVideo');

	src = "http://news.com.com/1607";
	src += "-";
	src += "2_3";
	src += "-";
	src += maceAssetId;
	src += "-";
	if (mPlayer=="hiasf") {
		src += "2";
		width = "320";
		height = "240";
		sizeIE  = "<param name=\"AutoSize\" value=\"False\">\n";
	} else if (mPlayer=="loasf") {
		src += "1";
		width = "160";
		height = "120";
		sizeIE  = "<param name=\"AutoSize\" VALUE=\"0\">\n";
		sizeIE += "<param name=\"DisplaySize\" value=\"0\">\n";
		sizeIE += "<PARAM NAME=\"ShowDisplay\" VALUE=\"False\">\n";
	}
	src += ".asx?PSDir=";
	src += prestream;
	src += "&PostDir=";
	src += poststream;
	src += "&videoName=";
	src += videoName;
	src += "&NumClips=";
	src += NumClips;
	str  = "<object id=\"videoie\" width=\"320\" height=\"240\"";
	str += " classid=\"CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95\"";
	str += " codebase=\"http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701\"";
	str += " standby=\"Loading Microsoft® Windows® Media Player components...\"";
	str += " type=\"application/x-oleobject\">\n";
	str += "<param name=\"FileName\" value=\"";
	str += src;
	str += "\">\n";
	str += "<param name=\"ShowStatusBar\" value=\"False\">\n";
	str += "<param name=\"ShowAudioControls\" value=\"False\">\n";
	str += "<param name=\"ShowControls\" value=\"False\">\n";
	str += sizeIE;
	str += "<embed type=\"application/x-mplayer2\"";
	str += " pluginspage = \"http://www.microsoft.com/Windows/MediaPlayer/\" src=\"";
	str += src;
	str += "\" name=\"videoie\" width=\"320\" height=\"240\" showstatusbar=\"0\"";
	str += " showaudiocontrols=\"0\" showcontrols=\"0\" autosize=\"0\"";
	str += ">\n";
	str += "</embed>\n";
	str += "</object>\n";
	return(str);
}



function asf_default_embed()
{
	var str,src;
	var mPlayer = getCookie('cnet_newsVideo');

	// If 'wm' is passed as the player type in the location string, default to windowsmedia.
	var args = getArgs();
	playerType = args.playtype;
	if (playerType == "wm") {
		mPlayer = "hiasf";
	}

	
	src = "http://news.com.com/1607";
	src += "-";
	src += "2_3";
	src += "-";
	src += maceAssetId;
	src += "-";
	if (mPlayer=="hiasf") {
		src += "2";
		width = "320";
		height = "240";
		sizeIE  = "<param name=\"AutoSize\" value=\"False\">\n";
		sizeNN = "";
	} else if (mPlayer=="loasf") {
		src += "1";
		width = "160";
		height = "120";
		sizeIE  = "<param name=\"AutoSize\" VALUE=\"0\">\n";
		sizeIE += "<param name=\"DisplaySize\" value=\"0\">\n";
		sizeIE += "<PARAM NAME=\"ShowDisplay\" VALUE=\"False\">\n";
		sizeNN = "displaysize=\"0\"";
	}
	src += ".asx?PSDir=";
	src += prestream;
	src += "&PostDir=";
	src += poststream;
	src += "&videoName=";
	src += videoName;
	src += "&NumClips=";
	src += NumClips;
	str  = "<object id=\"videoie\" width=\"320\" height=\"286\"";
	str += " classid=\"CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95\"";
	str += " codebase=\"http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701\"";
	str += " standby=\"Loading Microsoft® Windows® Media Player components...\"";
	str += " type=\"application/x-oleobject\">\n";
	str += "<param name=\"FileName\" value=\"";
	str += src;
	str += "\">\n";
	str += "<param name=\"ShowStatusBar\" value=\"False\">\n";
	str += "<param name=\"ShowAudioControls\" value=\"True\">\n";
	str += "<param name=\"ShowControls\" value=\"True\">\n";
	str += sizeIE;
	str += "<embed type=\"application/x-mplayer2\"";
	str += " pluginspage = \"http://www.microsoft.com/Windows/MediaPlayer/\" src=\"";
	str += src;
	str += "\" name=\"videoie\" width=\"320\" height=\"286\" showstatusbar=\"0\"";
	str += " showaudiocontrols=\"1\" showcontrols=\"1\" autosize=\"0\"";
	str += sizeNN;
	str += ">\n";
	str += "</embed>\n";
	str += "</object>\n";
	//alert(str);
	return(str);
}
