if(document.getElementById){
	document.writeln('<style type="text/css" media="all">');
	document.writeln('<!--');
	document.writeln('.sidehide{display:none}');
	document.writeln('-->');
	document.writeln('</style>');
}

function showHide(id){
	var disp = document.getElementById(id).style.display;
	if(disp == "block"){
		document.getElementById(id).style.display = "none";
	}
       else{
		document.getElementById(id).style.display = "none";
	}
	return false;
       }
function hideShow(id){
	var disp = document.getElementById(id).style.display;
	if(disp == "none"){
		document.getElementById(id).style.display = "block";
	}
       else{
		document.getElementById(id).style.display = "block";
	}
	return false;
       }

function rec(id){
	myExp = new Date();
	myExp.setTime(myExp.getTime()+(365*24*60*60*1000));
	tmp = "rec=" + escape(id) + ";";
	tmp += " path=/; expires=" + myExp.toGMTString();
	document.cookie = tmp;

}

function getCookie(){		//クッキーを取り出す関数
tmp = document.cookie + ";";
index1 = tmp.indexOf("rec",0);
if(index1 != -1){
	tmp = tmp.substring(index1,tmp.length);
	index2 = tmp.indexOf("=",0) + 1;
	index3 = tmp.indexOf(";",index2);
	return(unescape(tmp.substring(index2,index3)));
	}
else return ("0");	//子メニューの数だけ0を増やす
}

function shInit(){
	state=getCookie();
	if (state !="0")
	{
		document.getElementById(state).style.display = "block";
	}
}
