//	fWriteFlashObject(nID, sUrl, nWidth, nHeight, sBG, bTransparent, sCssClass)

function fWriteFlashObject(sID, sUrl, nWidth, nHeight, sBG, bTransparent, sCssClass){
	sSSL=(location.href.indexOf("https")>=0 ? "s" : "")

	document.write('<object id="'+ sID +'" width="'+ nWidth +'" height="'+ nHeight +'" class="'+ sCssClass +'" codebase="http'+ sSSL +'://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">')
	document.write('<param name="movie" value="'+ sUrl +'">')
	if(bTransparent) document.write('<param name="wmode" value="transparent" />');
	document.write('<param name="bgcolor" value="'+ sBG +'" />');
	document.write('<param name="quality" value="high">');
	document.write('<embed id="'+ sID +'" src="'+ sUrl +'" width="'+ nWidth +'" height="'+ nHeight +'" class="'+ sCssClass +'" bgcolor="'+ sBG +'" '+ (bTransparent ? 'wmode="transparent"' : '') +' quality="high"  TYPE="application/x-shockwave-flash" PLUGINSPAGE="http'+ sSSL +'://www.macromedia.com/go/getflashplayer"></embed>')
	document.write('</object>');
}

function OpenMenu(URL, newwin){
	if(newwin)
		window.open("/"+ URL)
	else
		top.location.href="/"+ URL
}

function fPlaceLogos(){
	try{
		nWindowWidth=(document.body.offsetWidth ? document.body.offsetWidth : document.width);

		if(nWindowWidth>=1024)
			document.getElementById("oLogos").style.paddingLeft=((nWindowWidth-1024)/2)+5;
		else
			document.getElementById("oLogos").style.paddingLeft="5px";
	}catch(e){}
}

function ViewPromo(URL){
		top.location.href=URL
}

function fChangepage(pageid){
	var sPageURL;
	switch(pageid){
		case 1: sPageURL="/cameras.asp"; break;
		case 2: sPageURL="/virtualTour.asp"; break;
		case 3: sPageURL="/today.asp"; break;
		default: sPageURL=null; break;
	}

	if(sPageURL) top.location.href=sPageURL;
}

function PopUp(id, width, height){
	//window.open("/popup.asp?id="+id,null,"width="+(width||530)+", height="+(height||300)+", scrollbars=yes, resizable=yes")
	top.location.href="/content.asp?back=1&id="+id
}

function fPopupWindow(url, width, height){
	window.open(url,"","width="+(width||530)+", height="+(height||300)+", scrollbars=yes, resizable=yes")
}

function OpenImage(img, CatID){

	window.open("/ImgPopUp.asp?img="+img + (CatID?"&CatID=" + CatID:""),null,"width=5,height=5")
}

function fPrintPage(){
	window.open('/print.html', 'winPrint', 'width=700, height=400, scrollbars=yes');
}