// マウスイベント
function funcMouse(d,f){
	if (f == 0){
		d.src = d.src.replace(/.gif/i,"_b.gif").replace(/.jpg/i,"_b.jpg");
	}else{
		d.src = d.src.replace(/_b.gif/i,".gif").replace(/_b.jpg/i,".jpg");
	}
}
//ウインドウオープン
function funcWinOpen(file,w,h,tool,menu,lo,bar,s,resize,l,r){
	
	str = 'left="+l+",top="+r+",toolbar='+tool+',menubar='+menu+',location='+lo+',status='+bar+',scrollbars='+s+',resizable='+resize+',width='+w+',height='+h;
	sub = window.open(file,"sub",str);
	sub.window.focus();
}
//著作権表示
function writeCopy(ny,co){
	var strYear = "";
	myD = new Date();
	myYear = myD.getYear();
	myYears = (myYear < 2000) ? myYear+1900 : myYear;//古いブラウザ用
	
	//次の年
	if(ny != myYears){
		strYear = "-"+myYears;
	}

	document.write("COPYRIGHT&copy;"+ny+" "+strYear+" "+co+" ALLRIGHT RESERVED.");

}
//---------------------------------------------------------------------------
// HTMLオブジェクト取得

function getObj( id )
{
	return document.all && document.all(id) || document.getElementById && document.getElementById(id);
}

function writeFlashTag( id, w, h, movie, quality, loop, bgcolor, wmode )
{
	var tag = "<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000'";
	tag += "codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0'";
	tag += "width='"+w+"' height='"+h+"'>";
	tag += "<param name='movie' value='"+movie+"'>";
	tag += "<param name='quality' value='"+quality+"'>";
	tag += "<param name='loop' value='"+loop+"'>";
	tag += "<param name='bgcolor' value='"+bgcolor+"'>";
	tag += "<param name='wmode'	value='"+wmode+"'>";
	tag += "<embed src='"+movie+"'";
	tag += "pluginspage='http://www.macromedia.com/go/getflashplayer'";
	tag += "width='"+w+"'";
	tag += "height='"+h+"'";
	tag += "loop='"+loop+"'";
	tag += "quality='"+movie+"'";
	tag += "bgcolor='"+bgcolor+"'";
	tag += "wmode='"+wmode+"'>";
	tag += "</object>";
	var obj = getObj( id );
	obj.innerHTML = ( tag );
}

