function showFlash(o){
	var bg,q,s,v,m,w;
	if(o.bgcolor){bg=o.bgcolor;}else{bg="#000000";}
	if(o.quality){q=o.quality;}else{q="high";}
	if(o.scale){s=o.scale;}else{s="noscale";}
	if(o.ver){v=o.ver;}else{v=6;}
	if(o.menu){m=o.menu;}else{m="true";}
    if(o.wmode){w=o.wmode;}else{w="default";}
	var str='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version='+v+',0,0,0" ';
	str+='id="'+o.id+'" ';
	if(o.base){str+='base="'+o.base+'" ';}
	if(o.aligh){str+='aligh="'+o.aligh+'" ';}
	str+='width="'+o.width+'" height="'+o.height+'"><param name="movie" value="'+o.name+'"/><param name="bgcolor" value="'+bg+'"/><param name="quality" value="'+q+'"/><param name="menu" value="'+m+'"/><param name="wmode" value="'+w+'"/>';
	if(o.flashvars){str+='<param name="flashvars" value="'+o.flashvars+'"/>';}
	if(o.salign){str+='<param name="salign" value="'+o.salign+'"/>';}
	str+='<param name="scale" value="'+s+'"/><embed type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" id="'+o.id+'-embed" src="'+o.name+'" bgcolor="'+bg+'" wmode="'+w+'" ';
	if(o.flashvars){str+='flashvars="'+o.flashvars+'" ';}
	str+='quality="'+q+'" ';
	if(o.base){str+='base="'+o.base+'" ';}
	if(o.salign){str+='salign="'+o.salign+'" ';}
	str+='scale="'+s+'" width="'+o.width+'" height="'+o.height+'"></embed></object>';
	document.writeln(str);
}

function initBanner(){
	var $obj = document.getElementById('banner');
	var WW = document.documentElement.clientWidth;
	document.getElementById('banner').style.right = ((WW - 551) / 2) -1 + "px";
	document.getElementById('banner').style.display = 'block';
}

function lightMenu($obj){
	var $td = $obj.parentNode.parentNode;
	if($td.className != "ON"){
		$td.className = 'light';
		var $target = $td.firstChild.nextSibling.nextSibling.nextSibling;
		$target.className = $target.className + "ANI";
	}
}
function dimMenu($obj){
	var $td= $obj.parentNode.parentNode;
	if($td.className != "ON"){
		$td.className = '';
		var $target = $td.firstChild.nextSibling.nextSibling.nextSibling;
		var $cutter = $target.className.split("ANI");
		$target.className = $cutter[0];
	}
}

function lightHMenu($obj){
	var $th = $obj.parentNode.parentNode;
	if($th.className != "ON"){
		var $target = $th.firstChild.firstChild;
		//alert($target.src);
		var $cutter = $target.src.split("_micon_");
		var $cutter2 = $cutter[1].split(".");
		var $newsrc = $cutter[0]+"_micon_"+$cutter2[0]+"ON."+$cutter2[1];
		$target.src = $newsrc;
	}
}
function dimHMenu($obj){
	var $th = $obj.parentNode.parentNode;
	if($th.className != "ON"){
		var $target = $th.firstChild.firstChild;
		var $cutter = $target.src.split("ON");
		var $newsrc = $cutter[0]+$cutter[1];
		$target.src = $newsrc;
	}
}

function popup_img (imageName, i_width, i_height) {
    //var i_width = 640;
    //var i_height = 640;
	var wx = (screen.width-i_width)/2;
	var wy = (screen.height-i_height)/2;
	var offset = ", left="+wx+",top="+wy;
    //imageName = "photos/"+imageName;
	image_popup = window.open(imageName, "Zoompad", "width=" + i_width + ", height=" + i_height + ", toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resize=no" + offset);
	if (window.focus) image_popup.focus();
    var d = image_popup.document;
        d.open();
        d.write('<body style="margin:0;"><img align="middle" src="'+imageName+'" /></body>');
        d.close();
}