// blog montlyリスト変更
function ChengeMonthlyList(d)
{
	var url;
	
	url = d.options[d.selectedIndex].value

	if( url != "" )
	{
		location.href=url;
	}

}

function init(page)
{
	// 共通
	initRollovers();
	writeFlashTag('navi', 260, 800, '/07/swf/navi.swf', 'autohigh', 'false', '#ffffff', 'transparent');

	//ホームのみ
	if(page == "home")
	{
		writeFlashTag('visual', 740, 300, '/07/swf/visual-home/visual-home.swf', 'autohigh', 'false', '#ffffff', 'transparent');
		writeFlashTag('slideshow', 220, 180, '/07/swf/slideshow/slideshow.swf?param_path=07/swf/slideshow/tennai/', 'autohigh', 'true', '#ffffff', 'transparent');
	}
	if(page == "soudan_form")
	{
		initLightbox();
    //new Validation(document.forms[0]); // OR new Validation(document.forms[0]);
	}
	if(page == "takuya_b")
	{
		writeFlashTag('slideshow', 220, 180, '/07/swf/slideshow/slideshow.swf?param_path=http://www.sugiyaku.com/07/swf/slideshow/takuya_b/', 'autohigh', 'true', '#ffffff', 'transparent');
	}
}


//---------------------------------------------------------------------------
// FLASH描画
//---------------------------------------------------------------------------
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 );
}

//---------------------------------------------------------------------------
// HTMLオブジェクト取得
//---------------------------------------------------------------------------
function getObj( id )
{
	return document.all && document.all(id) || document.getElementById && document.getElementById(id);
}

//---------------------------------------------------------------------------
//著作権表示
//---------------------------------------------------------------------------
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; 2004"+strYear+" "+co+" ALLRIGHT RESERVED.");

}

