//gen menu ver. 4.0



//level_1 = new Array('cindex.html' ,'whatsnew', 'aboutus', 'centre', 'press', 'health', 'student', 'related', 'resources', 'newsletters', '123', 'tools', 'ecards', 'games', 'contactus', 'sitemap', 'search', 'notices');
//level_1 = new Array('cindex.html' ,'whatsnew', 'aboutus', 'centre', 'health', 'related', 'resources', 'newsletters', 'tools', 'contactus', 'sitemap', 'search', 'notices');
level_1 = new Array('cindex.html' ,'whatsnew', 'aboutus', 'centre', 'health', 'related', 'resources', 'newsletters', 'hdtalk', 'tools', 'ecards', 'contactus', 'sitemap', 'search', 'notices');
//level 1



function genmenu(){

	//gentable(lev_div+'link','alt','img','target','layer');

	gentable(lev_div+'../cindex.html', '主頁', '01', '', '');

	gentable(lev_div+'whatsnew/whatsnew.html', '最新消息', '02', '', '');
	gentable(lev_div+'aboutus/aboutus.html', '關於我們', '03', '', 'y');
	gentable(lev_div+'centre/centre_gih.html', '中心資料', '04', '', '');
	//gentable(lev_div+'press/press.html', '新聞稿', '05', '', '');
	gentable(lev_div+'health/health.html', '健康資訊', '06', '', 'y');
	gentable(lev_div+'../wsmash/login.jsp', '學生登入', '07', '', '');
	gentable(lev_div+'related/related.html', '相關網頁', '08', '', '');
	gentable(lev_div+'resources/resources.html', '資源下載', '09', '', 'y');
	gentable(lev_div+'newsletters/newsletters.html', '《彩橋》通訊', '10', '', '');
	//gentable('http://www.ahpshs.gov.hk/tc_chi/dow_zon/dow_zon.php', 'AHP 資源下載中心', '14', '_blank', '');
	
	//20081209 Add Healthtalk
	//gentable(lev_div+'hdtalk/hdtalk.html', '健康講座時間表', '11', '', '');

	//gentable(lev_div+'tools/tools.html', '工具下載', '11', '', '');
	  gentable(lev_div+'tools/tools.html', '工具下載', '12', '', '');
	//gentable(lev_div+'ecards/index.html', '電子賀卡', '12', '', '');
	  gentable(lev_div+'ecards/index.html', '電子賀卡', '13', '', '');

	//gentable(lev_div+'games/games.html', '網絡遊戲', '13', '', '');
	gentable('', '聯絡我們', '', '', '');

	gentable('', '網站地圖', '', '', '');

	gentable('', '搜尋', '', '', '');

	gentable('', '重要告示', '', '', '');

	gendh();

}





//end level 1





// level 2

function genlayer(){	

	//genlaytab(lev_div+'link', 'alt', 'orgcolor', 'overcol','target', 'layer');



	for(l=0; l<layer.length; l++){

		if(layer[l] == "關於我們"){			

			genlayerheader(l);

			genlaytab(lev_div+'aboutus/aboutus_shs/aboutus_shs.html', '關於學生健康服務', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'aboutus/aboutus_shscsac/aboutus_shscsac.html', '關於學生健康服務中心/健康評估中心', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'aboutus/aboutus_ahp/aboutus_ahp.html', '關於青少年健康服務計劃', '#5ec219', '#fb7804','','');			
			genlayerfooter();



		}else if(layer[l] == "健康資訊"){			

			genlayerheader(l);

			genlaytab(lev_div+'health/health_hl/health_hl.html', '健康生活', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_dn/health_dn.html', '飲食與營養', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_pe/health_pe.html', '運動', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_bsh/health_bsh.html', '骨骼與脊柱健康', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_ev/health_ev.html', '眼睛/視力健康', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_ehs/health_ehs.html', '耳朵/聽覺健康/聲線', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_ophp/health_ophp.html', '其他身體健康問題', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_se/health_se.html', '性教育', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_ph/health_ph.html', '心理社交健康', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_sdsa/health_sdsa.html', '煙, 酒, 濫用藥物', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_lea/health_lea.html', '學習', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'health/health_cc/health_cc.html', '擇業', '#5ec219', '#fb7804','','');
			genlayerfooter();



		}else if(layer[l] == "資源下載"){

			genlayerheader(l);

			genlaytab(lev_div+'resources/resources_forms/resources_forms.html', '表格', '#5ec219', '#fb7804','','');
			genlaytab(lev_div+'resources/resources_bl/resources_bl.html', '單張/小冊子', '#5ec219', '#fb7804','','y');
			//genlaytab(lev_div+'hdtalk/hdtalk.html', '健康講座時間表', '#5ec219', '#fb7804','','');
			genlayerfooter();

		}
	}

}
	
function gensublayer(){
	//genlaytab(lev_div+'link', 'alt', 'orgcolor', 'overcol','target');
	for(l=0; l<sublayer.length; l++){

		if(sublayer[l] == "單張/小冊子"){		
			gensublayerheader(l);
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#1', '健康生活', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#2', '飲食與營養', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#3', '運動', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#4', '骨骼與脊柱健康', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#5', '眼睛/視力健康', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#6', '耳朵/聽覺健康/聲線', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#7', '其他身體健康問題', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#8', '性教育', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#9', '心理社交健康', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#10', '煙, 酒, 濫用藥物', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#11', '學習', '#5ec219', '#fb7804','');
			gensublaytab(lev_div+'resources/resources_bl/resources_bl.html#12', '擇業', '#5ec219', '#fb7804','');
			genlayerfooter();
		}
	}

}
//end level 2

