//===========================================================================
//基本設定
//==================== begin ================================================
topMargin = 112;    //內部為112
layerHeight = 23;
leftMargin = 90;
tableWidth = 200;
rowHeight = 22;
showWeekly = true;
showHouse = false;
path = '';    //內部為空字串
//====================  end  ================================================

//===========================================================================
//所有的menu
//==================== begin ================================================
menuNames = new Array('t','fo','p','so','int','c','o','e','life','sp','region','show');
titles = new Array('頭版新聞','焦點新聞','政治新聞','社會新聞','國際新聞','自由評論','自由廣場','財經焦點','生活新聞','體育新聞','地方新聞','影視名人');
pages = new Array('today-t1.htm','today-fo1.htm','today-p1.htm','today-so0.htm','today-int0.htm','today-s1.htm','today-o0.htm','today-e1.htm','today-life1.htm','today-sp0.htm','today-taipei0.htm','today-show1.htm');
if (!showWeekly)
{
	menuNames = menuNames.concat(new Array('supplement'));
	titles = titles.concat(new Array('生活副刊'));
	pages = pages.concat(new Array('today-fashion1.htm'));
}
menuNames2 = new Array('taipei','north','center','south','fashion','work','sex','family','article','travel');

names = menuNames.concat(menuNames2);
menus = Array(names.length);
for (i=0; i<menus.length; i++)
{
	menus[i] = new Object();
	menus[i].name = names[i];
}
//====================  end  ================================================

//===========================================================================
//主選單
//==================== begin ================================================
document.write('<TABLE class=block2L cellSpacing=1 cellPadding=3 width=90 border=0>');
document.write('	<TR>');
document.write('		<TD bgColor=#333399>今日要聞</TD>');
document.write('	</TR>');
for (i=0; i<menuNames.length; i++)
{
	document.write('	<TR>');
	document.write('		<TD class=block2L_tda onMouseOver="showMenu(this,'+menuNames[i]+')" onMouseOut="hideMenu()" style=color:blue;cursor:pointer');
	document.write('				onClick="location.href=\''+path+pages[i]+'\'">'+titles[i]+'</TD>');
	document.write('	</TR>');
}
if (true)
{
	document.write('	<TR>');
	document.write('		<TD class=block2L_tdb><A class=block2La href="#" onClick=open("http://www.libertytimes.com.tw/Service/weekly.htm","","toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,width=810,height=643")>生活週報</A></TD>');
	document.write('	</TR>');
}
if (false)
{
	document.write('	<TR>');
	document.write('		<TD class=block2L_tdb><A class=block2La href="#" onClick=open("http://www.libertytimes.com.tw/Service/house.htm","","toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,width=810,height=707")>住宅生活</A></TD>');
	document.write('	</TR>');
}
document.write('	<TR>');
document.write('		<TD bgColor=#cc6600><A class=block2La href="'+path+'Rnews.htm">專題報導</A></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD bgColor=#666666>服務專區</TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="http://www.roclotto.com.tw/" target=_blank>樂透彩券</A></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="'+path+'Nnews.htm">統一發票</A></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><font color=blue><A onmouseover="this.style.cursor=\'pointer\';this.style.color=\'deepskyblue\'" ');
document.write('			onclick="window.open(\'http://www.libertytimes.com.tw/Service/Order.htm\',\'_new\',\'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,width=770,height=650\');" ');
document.write('			onmouseout="this.style.color=\'blue\'">訂報服務</A></FONT></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="http://www.libertytimes.com.tw/about/recruit.htm">求才專區</a></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="'+path+'activity.htm">活動訊息</a></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="http://www.lscc.com.tw/" target=_blank>自由廣場<br>國際會議中心</a></TD>');
document.write('	</TR>');
document.write('	<TR>');
document.write('		<TD class=block2L_tdb><A class=block2La href="http://www.ntat.gov.tw/" target=_blank>台北市國稅局</a></TD>');
document.write('	</TR>');
document.write('</TABLE>');
//====================  end  ================================================

//===========================================================================
//所有的menu的項目，由PHP產生
//==================== begin ================================================

menu = getMenu('fo');
menu.layer = 1;
menu.menuLayer = 0;
menu.rows = new Array(6);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '擁抱父親 郝：報告總長，山頭攻下了';
	rows[0].link = 'today-fo1.htm';
																										
	rows[1].text = '謝贏士林大同 郝守住票倉';
	rows[1].link = 'today-fo2.htm';
																										
	rows[2].text = '馬：選舉結果 維持平盤';
	rows[2].link = 'today-fo3.htm';
																										
	rows[3].text = '保住綠色執政 陳菊：天佑高雄';
	rows[3].link = 'today-fo4.htm';
																										
	rows[4].text = '黃營提當選無效之訴';
	rows[4].link = 'today-fo5.htm';
																										
	rows[5].text = '菊，逆轉突圍 黃，錯估形勢';
	rows[5].link = 'today-fo6.htm';
																										
}
menu = null;

menu = getMenu('p');
menu.layer = 2;
menu.menuLayer = 0;
menu.rows = new Array(14);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '謝打漂亮一仗 綠政要肯定';
	rows[0].link = 'today-p1.htm';
																										
	rows[1].text = '黃營被控發走路工 古鋅酩僱車 檢追下落';
	rows[1].link = 'today-p2.htm';
																										
	rows[2].text = '內閣改組？ 政院未討論';
	rows[2].link = 'today-p3.htm';
																										
	rows[3].text = '宋宣布退出政壇 橘恐慌搶救主席';
	rows[3].link = 'today-p4.htm';
																										
	rows[4].text = '陳黃得票差距 本報民調最貼近';
	rows[4].link = 'today-p5.htm';
																										
	rows[5].text = '台聯敗 蘇進強︰我負責';
	rows[5].link = 'today-p6.htm';
																										
	rows[6].text = '兩大黨對決 提前確立';
	rows[6].link = 'today-p7.htm';
																										
	rows[7].text = '北市／親民黨剩2席 台聯搶灘2席';
	rows[7].link = 'today-p8.htm';
																										
	rows[8].text = '高市／國民黨奪17席 無黨籍7席';
	rows[8].link = 'today-p9.htm';
																										
	rows[9].text = '落選頭 高市正副議長敗北';
	rows[9].link = 'today-p10.htm';
																										
	rows[10].text = '北市正副議長選情初探：一黨獨大 議會龍頭 藍軍囊中物';
	rows[10].link = 'today-p11.htm';
																										
	rows[11].text = '高市正副議長選情初探：整合若成 正副議長 泛藍贏面大';
	rows[11].link = 'today-p12.htm';
																										
	rows[12].text = '日媒看選舉：馬領導力有問題';
	rows[12].link = 'today-p13.htm';
																										
	rows[13].text = '北檢查獲現金買票';
	rows[13].link = 'today-p14.htm';
																										
}
menu = null;

menu = getMenu('int');
menu.layer = 4;
menu.menuLayer = 0;
menu.rows = new Array(6);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = "軍政府怪招 斐濟登報徵閣員";
	rows[0].link = 'today-int1.htm';
																										
	rows[1].text = "雪花鬧罷工／歐陸暖冬 滑雪勝地改踏青";
	rows[1].link = 'today-int2.htm';
																										
	rows[2].text = "莫札特歌劇／伊德梅尼歐復演 先知道具頭不見了";
	rows[2].link = 'today-int3.htm';
																										
	rows[3].text = "戒毒所遭縱火 莫斯科45死";
	rows[3].link = 'today-int4.htm';
																										
	rows[4].text = "摩天樓槍戰 芝加哥4斷魂";
	rows[4].link = 'today-int5.htm';
																										
	rows[5].text = "《中英對照讀新聞》Writers put brave face on bad sex awards 作家故作鎮定領取最糟床戲獎";
	rows[5].link = 'today-int6.htm';
																										
}
menu = null;

menu = getMenu('so');
menu.layer = 3;
menu.menuLayer = 0;
menu.rows = new Array(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '7年前老師綁學生懸案 母淚泣：「義禮 會活著回來」';
	rows[0].link = 'today-so1.htm';
																										
	rows[1].text = '二戰台籍兵 失蹤30年返家';
	rows[1].link = 'today-so2.htm';
																										
	rows[2].text = '警強勢監控 「加蚋慶」低調出殯';
	rows[2].link = 'today-so3.htm';
																										
	rows[3].text = '楊慶順入土 大小老婆戰爭持續上演';
	rows[3].link = 'today-so4.htm';
																										
	rows[4].text = '護士拍嬰「自助吸奶」照 勒索院長';
	rows[4].link = 'today-so5.htm';
																										
	rows[5].text = '1日看護緣 10年姊弟情';
	rows[5].link = 'today-so6.htm';
																										
	rows[6].text = '18年的付出 換來金安獎';
	rows[6].link = 'today-so7.htm';
																										
	rows[7].text = '林真 路見不平掏腰包補路';
	rows[7].link = 'today-so8.htm';
																										
}
menu = null;

menu = getMenu('life');
menu.layer = 8;
menu.menuLayer = 0;
menu.rows = new Array(5);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '元旦起 遊覽車禁用再生胎';
	rows[0].link = 'today-life1.htm';
																										
	rows[1].text = '雪隧測速器 暗藏避車彎';
	rows[1].link = 'today-life2.htm';
																										
	rows[2].text = '發布死亡第1例 流感重症 突襲大學生';
	rows[2].link = 'today-life3.htm';
																										
	rows[3].text = '黃曆食物相剋圖 傳說沒根據';
	rows[3].link = 'today-life4.htm';
																										
	rows[4].text = '吃抗癲癇藥減肥 視力惡化';
	rows[4].link = 'today-life5.htm';
																										
}
menu = null;

menu = getMenu('sp');
menu.layer = 9;
menu.menuLayer = 0;
menu.rows = new Array(9);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '《杜哈亞運特別報導》網住第６金';
	rows[0].link = 'today-sp1.htm';
																										
	rows[1].text = '《杜哈亞運特別報導》林沅君 金喜';
	rows[1].link = 'today-sp2.htm';
																										
	rows[2].text = '《杜哈亞運特別報導》吳燕妮 銀恨';
	rows[2].link = 'today-sp3.htm';
																										
	rows[3].text = '《杜哈亞運特別報導》2公分之差 林家瑩驚險奪銅';
	rows[3].link = 'today-sp4.htm';
																										
	rows[4].text = '《杜哈亞運特別報導》教練場邊叫 金有用';
	rows[4].link = 'today-sp5.htm';
																										
	rows[5].text = '《杜哈亞運特別報導》蕭美玉 鐵騎鍍銀';
	rows[5].link = 'today-sp6.htm';
																										
	rows[6].text = '《杜哈亞運特別報導》奇蹟大逆轉 女排晉4';
	rows[6].link = 'today-sp7.htm';
																										
	rows[7].text = '佩提特、建仔 洋基新左右護法';
	rows[7].link = 'today-sp8.htm';
																										
	rows[8].text = '猴子回饋基層 孩子王';
	rows[8].link = 'today-sp9.htm';
																										
}
menu = null;

menu = getMenu('e');
menu.layer = 7;
menu.menuLayer = 0;
menu.rows = new Array(9);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '越南基金火熱 投資可變通';
	rows[0].link = 'today-e1.htm';
																										
	rows[1].text = '資訊月熱銷 筆電買氣最旺';
	rows[1].link = 'today-e2.htm';
																										
	rows[2].text = '日系液晶電視 帶動降價風';
	rows[2].link = 'today-e3.htm';
																										
	rows[3].text = '1080p高階電視 市場需求浮現';
	rows[3].link = 'today-e4.htm';
																										
	rows[4].text = '洪守傑開期貨課程 業界先鋒';
	rows[4].link = 'today-e5.htm';
																										
	rows[5].text = '金士頓 臉譜人像討喜';
	rows[5].link = 'today-e6.htm';
																										
	rows[6].text = '中國匯改緩慢 美失去耐心';
	rows[6].link = 'today-e7.htm';
																										
	rows[7].text = '公司週年慶 怡盛做公益慶祝';
	rows[7].link = 'today-e8.htm';
																										
	rows[8].text = '油價回穩 油國決不再減產';
	rows[8].link = 'today-e9.htm';
																										
}
menu = null;



menu = getMenu('t');
menu.layer = 0;
menu.menuLayer = 0;
menu.rows = new Array(1);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '北市長：郝龍斌 高市長：陳菊';
	rows[0].link = 'today-t1.htm';
																										
}
menu = null;

menu = getMenu('show');
menu.layer = 11;
menu.menuLayer = 0;
menu.rows = new Array(16);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '好爸爸屈中恆 恐被學校開除？';
	rows[0].link = 'today-show1.htm';
																										
	rows[1].text = 'Elva舊愛接力 陳冠希黃立行互尬';
	rows[1].link = 'today-show2.htm';
																										
	rows[2].text = '台灣藝人惹麻煩 陳冠希力挺';
	rows[2].link = 'today-show3.htm';
																										
	rows[3].text = '社長松浦 換裝取悅歌迷';
	rows[3].link = 'today-show4.htm';
																										
	rows[4].text = 'Ella拒當憋尿女 先解放再簽名';
	rows[4].link = 'today-show5.htm';
																										
	rows[5].text = '洪小鈴砸老本賣酒 男友人財相隨';
	rows[5].link = 'today-show6.htm';
																										
	rows[6].text = '蔣怡玩角色扮演 討男友歡心';
	rows[6].link = 'today-show7.htm';
																										
	rows[7].text = '梁詠琪不認男友 拿老媽當擋箭牌';
	rows[7].link = 'today-show8.htm';
																										
	rows[8].text = '夏于喬平7年恥 挺胸嗆聲';
	rows[8].link = 'today-show9.htm';
																										
	rows[9].text = '劉伯溫 豬狗逗陣討吉利';
	rows[9].link = 'today-show10.htm';
																										
	rows[10].text = '傑若米讚鞏俐全球最美  艾德爆料續集合約到手';
	rows[10].link = 'today-show11.htm';
																										
	rows[11].text = '芭黎絲車震露胸  情訂舊愛';
	rows[11].link = 'today-show12.htm';
																										
	rows[12].text = '娜姊穿皮草被轟  控制狂惹火老公';
	rows[12].link = 'today-show13.htm';
																										
	rows[13].text = '香取慎吾猴塞雷 壓柴崎幸收視NO.1';
	rows[13].link = 'today-show14.htm';
																										
	rows[14].text = '金惠秀演技讚 大學生最愛';
	rows[14].link = 'today-show15.htm';
																										
	rows[15].text = '高素榮當建商 買地皮蓋大樓';
	rows[15].link = 'today-show16.htm';
																										
}
menu = null;

menu = getMenu('c');
menu.layer = 5;
menu.menuLayer = 0;
menu.rows = new Array(3);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
		rows[0].text = '《今日社論》台灣人民守護本土價值深值兩黨重視';
		rows[0].link = 'today-s1.htm';
																	
	rows[1].text = '《自由談》平手的福氣！';
	rows[1].link = 'today-f1.htm';
																
		rows[2].text = '《鏗鏘集》馬英九敗了！';
		rows[2].link = 'today-f2.htm';
																	
}
menu = null;

menu = getMenu('region');
menu.layer = 10;
menu.menuLayer = 0;
menu.rows = new Array(4);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();

	rows[0].text = '大台北新聞　→';
	rows[0].submenu = 'taipei';
	rows[0].link = 'today-taipei0.htm';

	rows[1].text = '北部新聞　　→';
	rows[1].submenu = 'north';
	rows[1].link = 'today-north0.htm';

	rows[2].text = '中部新聞　　→';
	rows[2].submenu = 'center';
	rows[2].link = 'today-center0.htm';

	rows[3].text = '南部新聞　　→';
	rows[3].submenu = 'south';
	rows[3].link = 'today-south0.htm';
}
menu = null;

menu = getMenu('taipei');
menu.layer = 10;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(6);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '泛綠搶下20席 創議會新高';
	rows[0].link = 'today-taipei1.htm';
																										
	rows[1].text = '選務人員協助身障圈選 引發糾紛';
	rows[1].link = 'today-taipei2.htm';
																										
	rows[2].text = '選前飆淚 3人哭出第一高票';
	rows[2].link = 'today-taipei3.htm';
																										
	rows[3].text = '狂賊 「洗劫」整棟公寓';
	rows[3].link = 'today-taipei4.htm';
																										
	rows[4].text = '罵「你耍流氓」觸法被訴';
	rows[4].link = 'today-taipei5.htm';
																										
	rows[5].text = '大樓消防送水口遭竊 打火將陷水荒';
	rows[5].link = 'today-taipei6.htm';
																										
}
menu = null;

menu = getMenu('north');
menu.layer = 11;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '學排舞健身 風行新埔公所';
	rows[0].link = 'today-north1.htm';
																										
	rows[1].text = '原住民高唱詩歌 美聲繚繞雪管處';
	rows[1].link = 'today-north2.htm';
																										
	rows[2].text = '夫子秀魔法 校園變身馬戲團';
	rows[2].link = 'today-north3.htm';
																										
	rows[3].text = '風火輪四處跑 貢寮和美國小騎觀';
	rows[3].link = 'today-north4.htm';
																										
	rows[4].text = '林口到機場 108縣道新建有譜';
	rows[4].link = 'today-north5.htm';
																										
	rows[5].text = '宜市武營廟 180°大轉彎';
	rows[5].link = 'today-north6.htm';
																										
	rows[6].text = '母舅公樹有夠力 消防車改道';
	rows[6].link = 'today-north7.htm';
																										
	rows[7].text = '半百黃槿變分隔樹 人車閃邊';
	rows[7].link = 'today-north8.htm';
																										
}
menu = null;

menu = getMenu('center');
menu.layer = 12;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '水林蕃薯節開鑼 野炊更飄香';
	rows[0].link = 'today-center1.htm';
																										
	rows[1].text = '三國會戰 日月潭畔殺聲震天';
	rows[1].link = 'today-center2.htm';
																										
	rows[2].text = '嘉市3大工程浪費公帑 遭糾正';
	rows[2].link = 'today-center3.htm';
																										
	rows[3].text = '稻田運動會 泥巴戰拚高下';
	rows[3].link = 'today-center4.htm';
																										
	rows[4].text = '建仔簽名球 信望愛義賣45000元';
	rows[4].link = 'today-center5.htm';
																										
	rows[5].text = '歲末助貧童 拼布愛相連';
	rows[5].link = 'today-center6.htm';
																										
	rows[6].text = '股市栽跟頭 豐原聞人毒海沉淪';
	rows[6].link = 'today-center7.htm';
																										
	rows[7].text = '佯談生意詐賭 坑2廠商';
	rows[7].link = 'today-center8.htm';
																										
}
menu = null;

menu = getMenu('south');
menu.layer = 13;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '16席女議員 港都新紀錄';
	rows[0].link = 'today-south1.htm';
																										
	rows[1].text = '防跑票 正副議長選舉藍綠祭黨紀';
	rows[1].link = 'today-south2.htm';
																										
	rows[2].text = '雙蔡失利 地方人士惋惜';
	rows[2].link = 'today-south3.htm';
																										
	rows[3].text = '趙天麟高票落選 台聯僅1人上壘';
	rows[3].link = 'today-south4.htm';
																										
	rows[4].text = '七股洋香瓜節 甜蜜登場';
	rows[4].link = 'today-south5.htm';
																										
	rows[5].text = '美眉遇上色老鳥 告他性騷擾';
	rows[5].link = 'today-south6.htm';
																										
	rows[6].text = '單車砸機車 父子3人 抓盜了';
	rows[6].link = 'today-south7.htm';
																										
	rows[7].text = '假問路搶金鍊 鴛鴦盜落網';
	rows[7].link = 'today-south8.htm';
																										
}
menu = null;

menu = getMenu('o');
menu.layer = 6;
menu.menuLayer = 0;
menu.rows = new Array(10);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '敗選者：紅潮媒體';
	rows[0].link = 'today-o1.htm';
																										
	rows[1].text = '聞到希望的新鮮氣味';
	rows[1].link = 'today-o2.htm';
																										
	rows[2].text = '＜李筱峰專欄＞台灣沒有公平的選舉';
	rows[2].link = 'today-o3.htm';
																										
	rows[3].text = '自卑自戀，再見！';
	rows[3].link = 'today-o4.htm';
																										
	rows[4].text = '比感言 菊勝郝';
	rows[4].link = 'today-o5.htm';
																										
	rows[5].text = '繼續恐怖平衡';
	rows[5].link = 'today-o6.htm';
																										
	rows[6].text = '謝長廷 讚！';
	rows[6].link = 'today-o7.htm';
																										
	rows[7].text = '陳菊沒說的';
	rows[7].link = 'today-o8.htm';
																										
	rows[8].text = '等待泛藍學會民主';
	rows[8].link = 'today-o9.htm';
																										
	rows[9].text = '台灣唐人街';
	rows[9].link = 'today-o10.htm';
																										
}
menu = null;

if (showWeekly == false)
{
	menu = getMenu('supplement');
	menu.layer = 12;
	menu.menuLayer = 0;
	menu.rows = new Array(6);
	with (menu)
	{
		for (i=0; i<rows.length; i++)
			rows[i] = new Object();
	
		rows[0].text = '流行消費　　→';
		rows[0].submenu = 'fashion';
		rows[0].link = 'today-fashion1.htm';
	
		rows[1].text = '上班一族　　→';
		rows[1].submenu = 'work';
		rows[1].link = 'today-work1.htm';
	
		rows[2].text = '兩性異言堂　→';
		rows[2].submenu = 'sex';
		rows[2].link = 'today-sex1.htm';
	
		rows[3].text = '家庭親子　　→';
		rows[3].submenu = 'family';
		rows[3].link = 'today-family1.htm';
	
		rows[4].text = '自由副刊　　→';
		rows[4].submenu = 'article';
		rows[4].link = 'today-article1.htm';
	
		rows[5].text = '休閒旅遊　　→';
		rows[5].submenu = 'travel';
		rows[5].link = 'today-travel1.htm';
	}
	menu = null;
}

menu = getMenu('fashion');
menu.layer = 12;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

menu = getMenu('family');
menu.layer = 16;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

menu = getMenu('work');
menu.layer = 14;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

menu = getMenu('article');
menu.layer = 17;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

menu = getMenu('sex');
menu.layer = 15;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

menu = getMenu('travel');
menu.layer = 18;
menu.parentMenu = 'supplement';
menu.menuLayer = 1;
menu.rows = new Array(0);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
}
menu = null;

//====================  end  ================================================

//===========================================================================
//產生tables
//==================== begin ================================================
for (j=0; j<menus.length; j++)
{
	var previousRowType = '';
	if (menus[j].parentMenu == null)
		document.write('<table id='+menus[j].name+' style="position:absolute;left:'+(leftMargin+tableWidth*menus[j].menuLayer)+';visibility:hidden;font-size:13px;width:200;cursor:pointer;border:1 solid #00CCFF" border=0 bgcolor=#FFFFFF cellspacing=1 cellpadding=2 onMouseOver=showMenu(null,null) onMouseOut=hideMenu()>');
	else
		document.write('<table id='+menus[j].name+' style="position:absolute;left:'+(leftMargin+tableWidth*menus[j].menuLayer)+';visibility:hidden;font-size:13px;width:200;cursor:pointer;border:1 solid #00CCFF" border=0 bgcolor=#FFFFFF cellspacing=1 cellpadding=2 onMouseOver=showMenu2(null,null) onMouseOut=hideMenu2()>');

	for (i=0; i<menus[j].rows.length; i++)
	{
		if (previousRowType!='' && menus[j].rows[i].type==null)
		{
			document.write('<tr bgcolor=#00CCFF height=2 style=cursor:default>');
			document.write('	<td></td>');
			document.write('</tr>');
		}

		if (menus[j].rows[i].type && menus[j].rows[i].type!=previousRowType)
		{
			document.write('<tr bgcolor=#00CCFF height='+rowHeight+' style="cursor:default">');
			document.write('	<td>《'+menus[j].rows[i].type+'》</td>');
			document.write('</tr>');
		}

		if (menus[j].rows[i].submenu)
		{
			document.write('<tr onMouseOver="incell(this);showMenu2(this,'+menus[j].rows[i].submenu+')" onMouseOut="outcell(this);hideMenu2()" bgcolor=#C2E5FF height='+rowHeight+'>');
			if (menus[j].rows[i].link)
				document.write('	<td onClick="location.href=\''+path+menus[j].rows[i].link+'\'">'+menus[j].rows[i].text+'</td>');
			else
				document.write('	<td>'+menus[j].rows[i].text+'</td>');
			document.write('</tr>');
		}
		else 
		{
			if (menus[j].rows[i].type == null)
			{
				document.write('<tr onMouseOver=incell(this) onMouseOut=outcell(this) bgcolor=#C2E5FF height='+rowHeight+'>');
				document.write('	<td onClick="location.href=\''+path+menus[j].rows[i].link+'\'">◎'+menus[j].rows[i].text+'</td>');
				document.write('</tr>');
			}
			else
			{
				document.write('<tr onMouseOver=incell(this) onMouseOut=outcell2(this) bgcolor=#41DAAA height='+rowHeight+'>');
				document.write('	<td onClick="location.href=\''+path+menus[j].rows[i].link+'\'">．'+menus[j].rows[i].text+'</td>');
				document.write('</tr>');
			}
		}

		previousRowType = menus[j].rows[i].type==null? '': menus[j].rows[i].type;
	}

	document.write('</table>');
}
//====================  end  ================================================

var activeRow,activeMenu1,activeRow1,activeMenu2;
var protrude1;
var timer,timer2;
var hide,hide2

function getMenu(name)
{
	index = -1;
	for (i=0; i<menus.length; i++)
		if (menus[i].name == name)
		{
			index = i;
			break;
		}
	if (index != -1) return menus[index];
	else return null;
}

function showMenu(row,menu)
{
	if (activeRow)
	{
		hide = true;
		hideAllMenu();
	}
	hide = false;
	if (row)	activeRow = row;
	activeRow.style.backgroundColor = '#FFCCFF';
	if (menu) activeMenu1 = menu;
	
	defaultTop = topMargin+layerHeight*getMenu(activeMenu1.id).layer;
	protrude1 = defaultTop-document.body.scrollTop+activeMenu1.offsetHeight-document.body.clientHeight;
	if (protrude1 > 0)	
		activeMenu1.style.top = defaultTop-protrude1;
	else
		activeMenu1.style.top = defaultTop;
		
	activeMenu1.style.visibility = 'visible';
}

function hideMenu()
{
	clearTimeout(timer);
	hide = true;
	timer = setTimeout(hideAllMenu,600);
}

function hideAllMenu()
{
	if (hide)
	{
		activeRow.style.backgroundColor = '#FAF9F5';
		activeMenu1.style.visibility = 'hidden';
	}
}

function showMenu2(row,menu)
{
	if (activeRow1)
	{
		hide2 = true;
		hideAllMenu2();
	}
	hide = false;
	hide2 = false;
	if (row)	activeRow1 = row;
	activeRow.style.backgroundColor = '#FFCCFF';
	activeRow1.style.backgroundColor = '#FFCCFF';
	if (menu) activeMenu2 = menu;
	
	defaultTop = topMargin+layerHeight*getMenu(activeMenu2.id).layer;
	protrude2 = defaultTop-document.body.scrollTop+activeMenu2.offsetHeight-document.body.clientHeight;
	if (protrude2 > 0)	
	{
		if (protrude1 > protrude2)
			activeMenu2.style.top = defaultTop-protrude1;
		else
			activeMenu2.style.top = defaultTop-protrude2;
	}
	else
	{
		if (protrude1 > 0)
			activeMenu2.style.top = defaultTop-protrude1;
		else
			activeMenu2.style.top = defaultTop;
	}
	
	activeMenu1.style.visibility = 'visible';
	activeMenu2.style.visibility = 'visible';
}

function hideMenu2()
{
	hideMenu();
	clearTimeout(timer2);
	hide2 = true;
	timer2 = setTimeout(hideAllMenu2,600);
}

function hideAllMenu2()
{
	if (hide2) {
		activeRow1.style.backgroundColor = '#C2E5FF';
		activeMenu2.style.visibility = 'hidden';
	}
}

function outcell(cell)
{
	cell.style.backgroundColor = '#C2E5FF';
	cell.style.color = 'black';
}

function outcell2(cell)
{
	cell.style.backgroundColor = '#41DAAA';
	cell.style.color = 'black';
}

function incell(cell)
{
	cell.style.backgroundColor = '#FFCCFF';
	cell.style.color = 'blue';
}
