



function headerwrite(current,laydisp,list2){

//Xgέθ  >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

listArray = new Array(
	"0__w·₯A__/info/gakuchou/",
	"0__εwΜv__/info/enkaku/__19",
	"0__εwΜgDiPDFj__/info/pdf/sosiki.pdf__19",
	"0__LpX__/camp/__19",
	"0__{έEέυ__/info/setubi/socyanpa.html__19",
	"0__oΕ¨__/info/publish/__19",
	"0__wZ@lΘεw__/info/houjin/index.html__19",
	"0__―οiοj__http://risoukai.rikadai.jp/__19",
	"0__κοi±€ζ€οj__http://www.tus-koyokai.com/__19",
	"0__Ϋο__/ijikai/__19",
	"0__πΚANZX__/info/access/index.html__19",
	"last__wΚ__/info/index.html#gakuhi__19",
	"#",
	"1__wζκ__/fac/ri1_index.html__19",
	"1__Hwζκ__/fac/ko1_index.html__19",
	"1__ςw__/fac/yaku_index.html__19",
	"1__Hw__/fac/riko_index.html__19",
	"1__ξbHw__/fac/kiso_index.html__19",
	"1__ocw__/fac/keiei_index.html__19",
	"1__wζρ__/fac/ri2_index.html__19",
	"1__Hwζρ__/fac/ko2_index.html__19",
	"1__³{iew€Κj__/fac/liberal_index.html__19",
	"1__wκUΘ__/fac/math_sen.html__19",
	"1__VoX__/fac/syllabus/__19",
	"1__AEEiwξρ__/fac/shushoku/toppage.html__19",
	"last__iζΎ__/fac/shikaku/index.html__19",
	"#",
	"2__w€Θ__/grad/ri_index.html__19",
	"2__Hw€Θ__/grad/ko_index.html__19",
	"2__»w€Θ__/grad/sk_index.html__19",
	"2__Θw³η€Θ__/grad/kk_index.html__19",
	"2__ςw€Θ__/grad/yaku_index.html__19",
	"2__Hw€Θ__/grad/riko_index.html__19",
	"2__ξbHw€Θ__/grad/kiso_index.html__19",
	"2__ocw€Θ__/grad/keiei_index.html__19",
	"2__Ά½Θw€Θ__/grad/seimei_index.html__19",
	"2__ΘwZp<br>oc€Θ__http://ins.tus.ac.jp/__19",
	"2__ΫΞΠΘw€Θ__/grad/kasai_index.html__19",
	"2__Agεw@__/grad/renkei.html__19",
	"last__VoX__/fac/syllabus/__19",
	"#",
	"3__ZpocκU__http://most.tus.ac.jp/mot/__19",
	"last__mIΰYνͺκU__http://most.tus.ac.jp/mip/__19",
	"#",
	"4__€@\__/labo/research_synthesis.html__19",
	"4__Ά½Θw€__/labo/research_life.html__19",
	"4__ξρΘw³η€@\__/labo/research_info.html__19",
	"4__€―€Eσυ€__/labo/jutaku.html__19",
	"last__€@νZ^[__/labo/kiki/__19",
	"#",
	"5__s__/life/gyouji/index.html__19",
	"5__Nu__/life/club/index.html__19",
	"5__NuεοQΑ\θ__/life/gakusei_news/__19",
	"5__kΊ__/life/soudan/index.html__19",
	"5__§wΰ__/life/shougaku/index.html__19",
	"5__wΆx__/life/support/index.html__19",
	"last__ϋΔΰ__/life/madoguchi/madoguchi.html__19",
	"#"
);


//}EXI[o[ >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

//****NζΜέθ****
theLink = new Array(
	'/info/',
	'/fac/',
	'/grad/',
	'http://most.tus.ac.jp/',
	'/labo/',
	'/life/'
);
//****^[QbgΜέθ****
theTarget = new Array(
	'target="_top"',
	'target="_top"',
	'target="_top"',
	'target="_top"',
	'target="_top"',
	'target="_top"'
);
//****ALTΜέθ****
theAlt = new Array(
	'εwTv',
	'w',
	'εw@',
	'κεEεw@',
	'€',
	'wΆΆ'
);

//NN4V[Yp»θΟ
var nnfoot = "";
var nnhead1 = "";
var nnhead2 = "";

if(document.layers){
	nnfoot = "</layer>";
}

//C[έθ  >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
var tempbottom ="</td><td width=6><img src=/common/images/sp.gif width=6 height=2 border=0 alt=></td></tr></table><table border=0 cellspacing=0 cellpadding=0 width=130 bgcolor=#000000><tr><td><img src=/common/images/sp.gif width=2 height=6 border=0 alt=></td></tr></table>" +nnfoot+ "</div>";

var temp ="";

//[vΆ¬  ----------------
menuArray = new Array();
var num = "";


for (n in listArray){
	splitlist = new Array();
	splitlist = listArray[n].split('__');


	if (splitlist[0] != "#"){


		if (temp == ""){
			num = splitlist[0];

			if(document.layers){	//NN»θ
				nnhead1 = "<layer onmouseout=btnTimer() onmouseover=headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "')>";
				nnhead2 = "<layer onmouseout=headnavi2('menu" +num+ "'," +num+ ");btnTimer() onmouseover=headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "')>";
			}

			if (current == num){
				temp = "<div id=ID" +num+ ">" +nnhead1+ "<table border=0 cellspacing=0 cellpadding=0 width=130 bgcolor=#000000><tr><td width=6><img src=/common/images/sp.gif width=6 height=2 border=0 alt=></td><td width=118><table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td height=6></td></tr></table>";
			}else{
				temp = "<div id=ID" +num+ ">" +nnhead2+ "<table border=0 cellspacing=0 cellpadding=0 width=130 bgcolor=#000000><tr><td width=6><img src=/common/images/sp.gif width=6 height=2 border=0 alt=></td><td width=118><table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td height=6></td></tr></table>";
			}
			
		}
		if (splitlist[0] == "last"){
			if (current == num){
				var rooptemp = "<table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td onclick= location='"+splitlist[2]+"' onmouseout= btnTimer();this.bgColor='#000000' onmouseover= headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "');this.bgColor='#de590e';className='n'><table border=0 cellspacing=0 cellpadding=3 width=100%><tr><td class=text10 height=" +splitlist[3]+ "><a class=header href="+splitlist[2]+">" +splitlist[1]+ "</a></td></tr></table></td></tr></table>";
			}else{
				var rooptemp = "<table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td onclick= location='"+splitlist[2]+"' onmouseout= headnavi2('menu" +num+ "'," +num+ ");btnTimer();this.bgColor='#000000' onmouseover= headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "');this.bgColor='#de590e';className='n'><table border=0 cellspacing=0 cellpadding=3 width=100%><tr><td class=text10 height=" +splitlist[3]+ "><a class=header href="+splitlist[2]+">" +splitlist[1]+ "</a></td></tr></table></td></tr></table>";
			}

		}else{
			if (current == num){
				var rooptemp = "<table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td onclick= location='"+splitlist[2]+"' onmouseout= btnTimer();this.bgColor='#000000' onmouseover= headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "');this.bgColor='#de590e';className='n'><table border=0 cellspacing=0 cellpadding=3 width=100%><tr><td class=text10 height=" +splitlist[3]+ "><a class=header href="+splitlist[2]+">" +splitlist[1]+ "</a></td></tr></table><table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td><img src=/common/images/laymenuline.gif width=118 height=1 border=0 alt=></td></tr></table></td></tr></table>";
			}else{
				var rooptemp = "<table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td onclick= location='"+splitlist[2]+"' onmouseout= headnavi2('menu" +num+ "'," +num+ ");btnTimer();this.bgColor='#000000' onmouseover= headnavi1('menu" +num+ "'," +num+ ");showLayer('ID" +num+ "');this.bgColor='#de590e';className='n'><table border=0 cellspacing=0 cellpadding=3 width=100%><tr><td class=text10 height=" +splitlist[3]+ "><a class=header href="+splitlist[2]+">" +splitlist[1]+ "</a></td></tr></table><table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td><img src=/common/images/laymenuline.gif width=118 height=1 border=0 alt=></td></tr></table></td></tr></table>";

			}
		}

	temp += rooptemp;

	}else{
		temp += tempbottom;
		var m = menuArray.length;
		menuArray[m] = temp;
		temp = "";
	}

}

temp = "<div id=ID6></div>";
var m = menuArray.length;
menuArray[m] = temp;


var layerMenu = "";
for (i in menuArray){
	layerMenu += menuArray[i]
}


//C[ON,OFFέθiID6ͺσΖ·ιj----------------
defaultLyr='ID6';
onLayer=defaultLyr;

splitdata = new Array();
splitdata =  laydisp.split('__');


var GlobalMenu = '';
for(m=0;m<=5;m++){
	if (splitdata[m] == 'on'){
		if (current==m){
			GlobalMenu += '<a href="' +theLink[m]+ '" ' +theTarget[m]+'  onmouseover="showLayer(\'ID' +m+ '\')"><img src="/common/images/menu' +m+ '_r.gif" height="28" border="0" name="menu' +m+ '" alt="' +theAlt[m]+ '"></a>';
		}else{
			GlobalMenu += '<a href="' +theLink[m]+ '" onmouseover="headnavi1(\'menu' +m+ '\',' +m+ ');showLayer(\'ID' +m+ '\')"  onmouseout="headnavi2(\'menu' +m+ '\',' +m+ ');btnTimer()" ' +theTarget[m]+' ><img src="/common/images/menu' +m+ '.gif" height="28" border="0" name="menu' +m+ '" alt="' +theAlt[m]+ '"></a>';
		}
	}else{
		if (current==m){
			GlobalMenu += '<a href="' +theLink[m]+ '" ' +theTarget[m]+' ><img src="/common/images/menu' +m+ '_r.gif" height="28" border="0" name="menu' +m+ '" alt="' +theAlt[m]+ '"></a>';
		}else{
			GlobalMenu += '<a href="' +theLink[m]+ '" onmouseover="headnavi1(\'menu' +m+ '\',' +m+ ')"  onmouseout="headnavi2(\'menu' +m+ '\',' +m+ ')" ' +theTarget[m]+' ><img src="/common/images/menu' +m+ '.gif" height="28" border="0" name="menu' +m+ '" alt="' +theAlt[m]+ '"></a>';
		}
	}

}


var theLink2 = new Array(
     '/admis/',
     '/users/zaigaku.php',
     '/users/sotugyou.php',
     '/users/kigyou.php',
     '/users/fubo.php'
);

var str = location.href;
var loc = -1;
if(str.indexOf("admis") >0 ){
  loc =0;
}
if(str.indexOf("zaigaku") >0 ){
  loc =1;
}
if(str.indexOf("sotugyou") >0 ){
  loc =2;
}
if(str.indexOf("kigyou") >0 ){
  loc =3;
}
if(str.indexOf("fubo") >0 ){
  loc =4;
}

var GlobalMenu2 = '';

GlobalMenu2 += '<table border="0" cellspacing="0" cellpadding="0" width="100%"><tr><td>';

for(m=0;m<=4;m++){

if(m == 4 && navigator.appName == 'Netscape'){
   w=138;
}
else{
   w=134;
} 

if(m == loc){
GlobalMenu2 += '<img src="/common/images/menu_u' +m+ '_r.jpg" width="' +w+ '" height="19" border="0" name="menu_u' +m+ '">';
}
else{
GlobalMenu2 += '<a href="' +theLink2[m]+  '"  onMouseOver="headnavi2_1(\'menu_u' +m+ '\',' +m+ ')", onMouseOut="headnavi2_2(\'menu_u' +m+ '\',' +m+ ')"><img src="/common/images/menu_u' +m+ '.jpg" width="' +w+ '" height="19" border="0" name="menu_u' +m+ '"></a>';
}

}

GlobalMenu2 += '</td></tr></table>';

if (list2 == 'off'){
	GlobalMenu2 = ''
  }


//ev[g  ----------------

//ΘεS
var template = '<a name="top"></a><table border="0" cellspacing="0" cellpadding="0" width="670" bgcolor="#ffffff"><tr><td height="15"></td></tr></table><table border="0" cellspacing="0" cellpadding="0" width="100%"><tr valign="bottom"><td width="0%"><a href="/" target="_top"><img src="/common/images/tus_logo.gif" width="168" height="45" border="0" alt="Θεw"></a></td><td width="0%"><img src="/common/images/sp.gif" width="15" height="2" border="0" alt=""></td>'
// gbvy[WEpκgbvΦΜN
template += '<td width="0%"><table border="0" cellspacing="0" cellpadding="0"><tr><td><a href="/indexj.php" target="_top"><img src="/common/images/to_top.gif" width="40" height="11" border="0" alt=""></a></td></tr><tr><td><img src="/common/images/sp.gif" width="30" height="4" border="0" alt=""></td></tr><tr valign"bottom"><td><a href="/en/" target="_top"><img src="/common/images/to_english.gif" width="69" height="11" border="0" alt=""></a></td></tr></tr><tr valign="bottom"><td><img src="/common/images/sp.gif" width="75" height="1" border="0" alt=""></td></tr></table>'
// πΚANZXE¨β’νΉΦΜN
template += '</td><td width="0%"><img src="/common/images/sp.gif" width="25" height="2" border="0" alt=""></td><td><a href="/info/access/kagcamp.html"><img src="/common/images/access2.gif" width="76" height="14" border="0" alt=""></a></td><td width="0%"><img src="/common/images/sp.gif" width="5" height="2" border="0" alt=""></td><td><a href="/utility/contact/"><img src="/common/images/otoiawase.gif" width="80" height="13" border="0" alt=""></a></td><td width="0%"><img src="/common/images/sp.gif" width="5" height="2" border="0" alt=""></td>'
// TCgΰυ
template += '<td width="100%" align="right" ><table border="0" cellspacing="0" cellpadding="0"><tr valign="bottom"><td colspan="2"><img src="/common/images/sa_text.gif"></td></tr><tr valign="bottom"><td><img src="/common/images/sp.gif" width="30" height="1" border="0" alt=""></td></tr><tr valign=bottom><td ><form style="margin-bottom: 0px;" id="searchbox_014865889877293365565:rwcc0ynusug" action="/search.html"><input type="hidden" name="cx" value="014865889877293365565:rwcc0ynusug"><input name="q" type="text" size="20"><input type="hidden" name="cof" value="FORID:11"><input type="hidden" name="safe" value="active" /><input type="hidden" name="ie" value="Shift_JIS" /></td><td><input value="" name="sa" type="image" src="/common/images/search_btn.gif" width="46" height="22" style="margin-top: 0px;"></form><script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=searchbox_014865889877293365565%3Arwcc0ynusug"></script></td></tr></table></td><td width="0%"><img src="/common/images/sp.gif" width="5" height="2" border="0" alt=""></td></tr></table><table border="0" cellspacing="0" cellpadding="0" width="100%"><tr><td height="7"></td></tr></table><table border="0" cellspacing="0" cellpadding="0" width="100%"><tr><td nowrap background="/common/images/header_bg.gif">'
// O[oj[
template += GlobalMenu + '</td></tr></table>'+ layerMenu + GlobalMenu2 ;


//oΝ
	document.write(template);
}




//}EXI[o[ΦiTu[`j/////////////////////////////
var OverImg = new Array();
var OutImg = new Array();

for(i=0;i<=5;i++){
OutImg[i] = new Image;
OutImg[i].src = '/common/images/menu' + i + '.gif';
}

for(i=0;i<=5;i++){
OverImg[i] = new Image;
OverImg[i].src = '/common/images/menu' + i + '_r.gif';
}

function headnavi1(nam,num){
document.images[nam].src = OverImg[num].src;
}
function headnavi2(nam,num){
document.images[nam].src = OutImg[num].src;
}


 var img = new Array();

 img[0] = new Image();img[0].src = "/common/images/left_navi_r.gif";
 img[1] = new Image();img[1].src = "/common/images/left_navi.gif";
 img[2] = new Image();img[2].src = "/common/images/left_navi2.gif";

function _in(nam,num) {

 document.images[nam].src = img[num].src;

 return false;

}


//}EXI[o[ΦQiO[oj[pj/////////////////////////////

var OverImg2 = new Array();
var OutImg2 = new Array();

for(i=0;i<=4;i++){
OutImg2[i] = new Image;
OutImg2[i].src = '/common/images/menu_u' + i + '.jpg';
}

for(i=0;i<=4;i++){
OverImg2[i] = new Image;
OverImg2[i].src = '/common/images/menu_u' + i + '_r.jpg';
}


function headnavi2_1(nam,num){
document.images[nam].src = OverImg2[num].src;
}
function headnavi2_2(nam,num){
document.images[nam].src = OutImg2[num].src;
}



//T[`ΦiTu[`j/////////////////////////////

function seek1SetCols(v) {
	for (i=0;i<document.seek1.elements.length;i++) {
		if (document.seek1.elements[i].name=='col') {
			document.seek1.elements[i].checked=v
		}
	}
}



