 UIdir = "/shared/img/";


function writeSW(filename , Bg , Width , Height , nonFlashimg , Alt , pm , cm){

			if (pm == null){
			flashObj = filename + ".swf";
			} else {
			flashObj = filename + ".swf?pm=" + pm + "&cm=" + cm;
			}

		document.open();
			document.write('<div>');
			if (bw.flash5){
				document.write('<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\"' + Width + '\" height=\"' + Height + '\">');
				document.write('<param name=\"movie\" value=\"' + flashObj + '\">');
				document.write('<param name=\"quality\" value=\"high\">');
				document.write('<param name=\"bgcolor\" value=\"#'+ Bg +'\">');
				document.write('<param name=\"scale\" value=\"noscale\">');
				document.write('<param name=\"menu\" value=\"false\">');
				document.write('<embed src=\"' + flashObj + '\" quality=\"high\" bgcolor=\"#'+ Bg +'\"  width=\"' + Width + '\" height=\"' + Height + '\" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" menu=\"false\"></embed>');
				document.write('</object>');
			} else if(!bw.flash5 && nonFlashimg == 1){
				document.write('<a href=\"http://www.macromedia.com/jp/shockwave/download/?P1_Prod_Version=ShockwaveFlash&Lang=Japanese\" target=\"_blank\"><img src=\"img/flash_dl.gif\" width=\"' + Width + '\" height=\"' + Height + '\" border=\"0\" alt=\"'+ Alt +'\"></a>');
			} else if(!bw.flash5 && nonFlashimg == 0){
				document.write('<img src=\"'+ UIdir+'menubar.gif\" width=\"' + Width + '\" height=\"21\" border=\"0\" alt=\"\" usemap=\"#menubar\">');
			}
		document.write('</div>' + '\n');
		document.close();
}



function writeSW_main(filename , Bg , Width , Height , nonFlashimg , Alt , pm , cm , CookieUSE , CookieName){


		if (pm == null){
		flashObj = filename + ".swf";
		} else {
		flashObj = filename + ".swf?pm=" + pm + "&cm=" + cm;
		}

		if (CookieUSE == 1){
			var C = readCookie(CookieName);
			flashObj = flashObj + "?visit=" + C;
		} else {
			flashObj = flashObj;
		}



		document.open();
			document.write('<div>');
			if (bw.flash5){
				document.write('<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\"' + Width + '\" height=\"' + Height + '\">');
				document.write('<param name=\"movie\" value=\"' + flashObj + '\">');
				document.write('<param name=\"quality\" value=\"high\">');
				document.write('<param name=\"bgcolor\" value=\"#'+ Bg +'\">');
				document.write('<param name=\"scale\" value=\"noscale\">');
				document.write('<param name=\"menu\" value=\"false\">');
				document.write('<embed src=\"' + flashObj + '\" quality=\"high\" bgcolor=\"#'+ Bg +'\"  width=\"' + Width + '\" height=\"' + Height + '\" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" menu=\"false\"></embed>');
				document.write('</object>');
			} else if(!bw.flash5 && nonFlashimg == 1){
				document.write('<a href=\"http://www.macromedia.com/jp/shockwave/download/?P1_Prod_Version=ShockwaveFlash&Lang=Japanese\" target=\"_blank\"><img src=\"img/flash_dl.gif\" width=\"' + Width + '\" height=\"' + Height + '\" border=\"0\" alt=\"'+ Alt +'\"></a>');
			} else if(!bw.flash5 && nonFlashimg == 0){
				document.write('<img src=\"'+ UIdir+'notice.gif\" width=\"' + Width + '\" height=\"'+ Height +'\" border=\"0\" alt=\"\">');
			}
		document.write('</div>' + '\n');
		document.close();
}
