//===========================================================================
//基本設定
//==================== 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','stock','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-stock1.htm','today-life1.htm','today-sp0.htm','today-taipei0.htm','today-show1.htm');
if (showWeekly)
{
	menuNames = menuNames.concat(new Array('weekly'));
	titles = titles.concat(new Array('週末生活版'));
	pages = pages.concat(new Array('today-weekly1.htm'));
}
else
{
	menuNames = menuNames.concat(new Array('supplement'));
	titles = titles.concat(new Array('生活藝文'));
	pages = pages.concat(new Array('today-fashion1.htm'));
}
if (showHouse)
{
	menuNames = menuNames.concat(new Array('house'));
	titles = titles.concat(new Array('住宅生活版'));
	pages = pages.concat(new Array('today-house1.htm'));
}
menuNames2 = new Array('taipei','north','center','south','fashion','family','medicine','article','art','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>');
}
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('</TABLE>');
//====================  end  ================================================

//===========================================================================
//所有的menu的項目，由PHP產生
//==================== begin ================================================

menu = getMenu('fo');
menu.layer = 1;
menu.menuLayer = 0;
menu.rows = new Array(10);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '350萬買中廣屋 收回4億國有地';
	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';
																										
	rows[6].text = '油價又漲 將吃掉經濟成長率';
	rows[6].link = 'today-fo7.htm';
																										
	rows[7].text = '晶片卡匆促上路 漏洞百出';
	rows[7].link = 'today-fo8.htm';
																										
	rows[8].text = '高油價 精打細算 多少撿便宜';
	rows[8].link = 'today-fo9.htm';
																										
	rows[9].text = '台鐵柵欄年損3700支 虧損5000萬';
	rows[9].link = 'today-fo10.htm';
																										
}
menu = null;

menu = getMenu('p');
menu.layer = 2;
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-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 = '政院目標：2015年每人GDP達32000美元';
	rows[5].link = 'today-p6.htm';
																										
	rows[6].text = '228紀念館擇定前美新處';
	rows[6].link = 'today-p7.htm';
																										
	rows[7].text = '綠籲馬 訪日當做學習之旅';
	rows[7].link = 'today-p8.htm';
																										
	rows[8].text = '親征首都 宋號角將響';
	rows[8].link = 'today-p9.htm';
																										
	rows[9].text = '陳菊求見 李登輝婉拒';
	rows[9].link = 'today-p10.htm';
																										
}
menu = null;

menu = getMenu('int');
menu.layer = 4;
menu.menuLayer = 0;
menu.rows = new Array(9);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = "62歲英婦生下試管男嬰";
	rows[0].link = 'today-int1.htm';
																										
	rows[1].text = "巴西9歲女童 剖腹產子";
	rows[1].link = 'today-int2.htm';
																										
	rows[2].text = "女高音沃特 切胃救事業";
	rows[2].link = 'today-int3.htm';
																										
	rows[3].text = "成吉思汗子孫 走出紅色憂鬱";
	rows[3].link = 'today-int4.htm';
																										
	rows[4].text = "飛彈危機 美首肯與北韓會談";
	rows[4].link = 'today-int5.htm';
																										
	rows[5].text = "野果催情 以形補形";
	rows[5].link = 'today-int6.htm';
																										
	rows[6].text = "奔牛抓狂 頂傷遊客";
	rows[6].link = 'today-int7.htm';
																										
	rows[7].text = "《中英對照讀新聞》Shoppers want long Sunday hours 購物者希望星期天商店營業時間加長";
	rows[7].link = 'today-int8.htm';
																										
	rows[8].text = "《中日對照讀新聞》小林尊&#12373;&#12435;&#12364;早食&#12356;&#12391;新記&#37682; 小林尊締造競食新紀錄";
	rows[8].link = 'today-int9.htm';
																										
}
menu = null;

menu = getMenu('so');
menu.layer = 3;
menu.menuLayer = 0;
menu.rows = new Array(12);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '告官告親 婦洗冤寫狀25年';
	rows[0].link = 'today-so1.htm';
																										
	rows[1].text = '4口之家 南非台商慘遭滅門';
	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 = '撤通姦告訴 空姐再告 檢不起訴';
	rows[5].link = 'today-so6.htm';
																										
	rows[6].text = '本報獨家報導／總統來了 張俊傑 唇語秀英文';
	rows[6].link = 'today-so7.htm';
																										
	rows[7].text = '亡兒衣捐愛滋兒 母愛溫度延續';
	rows[7].link = 'today-so8.htm';
																										
	rows[8].text = '火爆里長管家公 粉絲眾多';
	rows[8].link = 'today-so9.htm';
																										
	rows[9].text = '小花免費教學 家扶孩子一圓鋼琴夢';
	rows[9].link = 'today-so10.htm';
																										
	rows[10].text = '愛心人物誌─楊明義 樂當情緒垃圾桶';
	rows[10].link = 'today-so11.htm';
																										
	rows[11].text = '愛心人物誌─小朱 火鳳凰鼓勵你做主';
	rows[11].link = 'today-so12.htm';
																										
}
menu = null;

menu = getMenu('life');
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 = '95度酒精可食？ 標示嚇人';
	rows[0].link = 'today-life1.htm';
																										
	rows[1].text = '颱風今遠離 中南部防豪雨';
	rows[1].link = 'today-life2.htm';
																										
	rows[2].text = '高縣大雨 搶收蔬菜顧生計';
	rows[2].link = 'today-life3.htm';
																										
	rows[3].text = '陳培哲 致力傳承人文典範與研究熱情';
	rows[3].link = 'today-life4.htm';
																										
	rows[4].text = '98年加考公民 教師家長都反對';
	rows[4].link = 'today-life5.htm';
																										
	rows[5].text = '捕狗隊 掄棒亂打 捉狗變虐狗';
	rows[5].link = 'today-life6.htm';
																										
	rows[6].text = '單身、同志  收養小孩非夢事';
	rows[6].link = 'today-life7.htm';
																										
	rows[7].text = '1200公里環島長征  台師大鐵騎榮歸';
	rows[7].link = 'today-life8.htm';
																										
	rows[8].text = '改裝有理 千輛吉普車遊街嗆聲';
	rows[8].link = 'today-life9.htm';
																										
}
menu = null;

menu = getMenu('sp');
menu.layer = 10;
menu.menuLayer = 0;
menu.rows = new Array(10);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '《2006世界盃足球賽》金錢與榮譽之爭';
	rows[0].link = 'today-sp1.htm';
																										
	rows[1].text = '《2006世界盃足球賽》求勝渴望 左右勝負';
	rows[1].link = 'today-sp2.htm';
																										
	rows[2].text = '《2006世界盃足球賽》不老林 多的是自信';
	rows[2].link = 'today-sp3.htm';
																										
	rows[3].text = '《2006世界盃足球賽》盯死席丹 義軍布防';
	rows[3].link = 'today-sp4.htm';
																										
	rows[4].text = '《2006世界盃足球賽》真的是最後一戰';
	rows[4].link = 'today-sp5.htm';
																										
	rows[5].text = '《2006世界盃足球賽》2010世界盃 南非等待奇蹟';
	rows[5].link = 'today-sp6.htm';
																										
	rows[6].text = '我宰日 狂勝43分';
	rows[6].link = 'today-sp7.htm';
																										
	rows[7].text = '鯨大口吞象';
	rows[7].link = 'today-sp8.htm';
																										
	rows[8].text = '潘忠韋 棒打獅';
	rows[8].link = 'today-sp9.htm';
																										
	rows[9].text = '溫網 男人婆封后';
	rows[9].link = 'today-sp10.htm';
																										
}
menu = null;

menu = getMenu('e');
menu.layer = 7;
menu.menuLayer = 0;
menu.rows = new Array(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '少子化 玩具消費3年逆增47%';
	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 = '上網爬格子 也可賺錢';
	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 = '官司影響 崇貿營收連2月下滑';
	rows[6].link = 'today-e7.htm';
																										
	rows[7].text = '金管會代主委呂東英否認辭職';
	rows[7].link = 'today-e8.htm';
																										
}
menu = null;

menu = getMenu('stock');
menu.layer = 8;
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-stock1.htm';
																										
	rows[1].text = '南韓停止升息 激勵股市上揚';
	rows[1].link = 'today-stock2.htm';
																										
	rows[2].text = '經濟趨緩 美股利多';
	rows[2].link = 'today-stock3.htm';
																										
	rows[3].text = '歐股下半年 大有可為';
	rows[3].link = 'today-stock4.htm';
																										
	rows[4].text = '併購頻仍 加碼資本財類股';
	rows[4].link = 'today-stock5.htm';
																										
	rows[5].text = '油價預期走高 能源類股看好';
	rows[5].link = 'today-stock6.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 = 12;
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 = '觀月嗆李晉良 愛劈腿 沒資格談衛生';
	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 = '法義爭冠 今夜你押誰？';
	rows[4].link = 'today-show5.htm';
																										
	rows[5].text = '吳建豪半裸挑逗 5千粉絲高潮';
	rows[5].link = 'today-show6.htm';
																										
	rows[6].text = '楊丞琳梁洛施激愛 狂罵飆淚';
	rows[6].link = 'today-show7.htm';
																										
	rows[7].text = '神棍暫居第2 猛追這位太太';
	rows[7].link = 'today-show8.htm';
																										
	rows[8].text = '鄭有傑 百萬首獎大贏家';
	rows[8].link = 'today-show9.htm';
																										
	rows[9].text = '台北電影節開啟國片希望';
	rows[9].link = 'today-show10.htm';
																										
	rows[10].text = '方馨1集喊價7萬 民視成人劇場退貨';
	rows[10].link = 'today-show11.htm';
																										
	rows[11].text = '陳霆拍拖陳怡真妹妹';
	rows[11].link = 'today-show12.htm';
																										
	rows[12].text = '娜姊踹開布蘭妮 勾引 潔西卡 琳西 玩SM';
	rows[12].link = 'today-show13.htm';
																										
	rows[13].text = '精靈落入水中 布萊絲謎樣的女人';
	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 = 11;
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 = 11;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(11);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '檢舉好友外遇 賞金一萬？';
	rows[0].link = 'today-taipei1.htm';
																										
	rows[1].text = '麥當勞大盜 專偷手機變賣';
	rows[1].link = 'today-taipei2.htm';
																										
	rows[2].text = '動物園夜未眠 湧入上萬人';
	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';
																										
	rows[6].text = '北縣體育季開跑 馬拉松3個月';
	rows[6].link = 'today-taipei7.htm';
																										
	rows[7].text = '宜蘭06音樂季 週末狂熱夜';
	rows[7].link = 'today-taipei8.htm';
																										
	rows[8].text = '基隆航海嘉年華登場 重溫當年遠征史';
	rows[8].link = 'today-taipei9.htm';
																										
	rows[9].text = '原民獎學金頒獎 出席人不到3成';
	rows[9].link = 'today-taipei10.htm';
																										
	rows[10].text = '三重大同公園改造 耳目一新';
	rows[10].link = 'today-taipei11.htm';
																										
}
menu = null;

menu = getMenu('north');
menu.layer = 12;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(5);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '機警婦反詐騙 匯10元報警抓';
	rows[0].link = 'today-north1.htm';
																										
	rows[1].text = '欠繳話費？ 副教授被騙70萬';
	rows[1].link = 'today-north2.htm';
																										
	rows[2].text = '通緝女外勞攔車 便服警逮正著';
	rows[2].link = 'today-north3.htm';
																										
	rows[3].text = '3毒蟲被逮 孕婦毒癮發送醫';
	rows[3].link = 'today-north4.htm';
																										
	rows[4].text = '《社會傳真》離奇車禍 情侶摔車1死1傷';
	rows[4].link = 'today-north5.htm';
																										
}
menu = null;

menu = getMenu('center');
menu.layer = 13;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(7);
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 = '網購被劫標、詐財 2女失金';
	rows[2].link = 'today-center3.htm';
																										
	rows[3].text = '假刑警辦案 老榮民棺材本飛了';
	rows[3].link = 'today-center4.htm';
																										
	rows[4].text = '少女劈腿 2男火併 警鳴槍制止';
	rows[4].link = 'today-center5.htm';
																										
	rows[5].text = '家庭式應召站 房內雲雨 房外讀經';
	rows[5].link = 'today-center6.htm';
																										
	rows[6].text = '《社會頻道》自家鐵捲門壓頸 男子氣絕';
	rows[6].link = 'today-center7.htm';
																										
}
menu = null;

menu = getMenu('south');
menu.layer = 14;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(9);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '南部治安檢討會 7犯罪列掃蕩重點';
	rows[0].link = 'today-south1.htm';
																										
	rows[1].text = '南打中心將設第二隊 擬遷至岡山';
	rows[1].link = 'today-south2.htm';
																										
	rows[2].text = '攔檢小客車 查獲18包毒品';
	rows[2].link = 'today-south3.htm';
																										
	rows[3].text = '太郎原是狼 友人女兒遭殃';
	rows[3].link = 'today-south4.htm';
																										
	rows[4].text = '卡陰為由 性侵少女求刑10年';
	rows[4].link = 'today-south5.htm';
																										
	rows[5].text = '弒父案子釋回 檢將釐清動機';
	rows[5].link = 'today-south6.htm';
																										
	rows[6].text = '砍母60刀致死 子判無期徒刑';
	rows[6].link = 'today-south7.htm';
																										
	rows[7].text = '恨不應該';
	rows[7].link = 'today-south8.htm';
																										
	rows[8].text = '水溝蓋竊案 當場逮3嫌';
	rows[8].link = 'today-south9.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 = 13;
	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 = 'family';
		rows[1].link = 'today-family1.htm';
	
		rows[2].text = '健康醫療　　→';
		rows[2].submenu = 'medicine';
		rows[2].link = 'today-medicine1.htm';
	
		rows[3].text = '自由副刊　　→';
		rows[3].submenu = 'article';
		rows[3].link = 'today-article1.htm';
	
		rows[4].text = '藝術文化　　→';
		rows[4].submenu = 'art';
		rows[4].link = 'today-art1.htm';
	
		rows[5].text = '休閒旅遊　　→';
		rows[5].submenu = 'travel';
		rows[5].link = 'today-travel1.htm';
	}
	menu = null;
}

menu = getMenu('fashion');
menu.layer = 13;
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 = 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('medicine');
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('article');
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('art');
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('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;

if (showWeekly)
{
	menu = getMenu('weekly');
	menu.layer = 13;
	menu.menuLayer = 0;
	menu.rows = new Array(12);
	with (menu)
	{
		for (i=0; i<rows.length; i++)
			rows[i] = new Object();
																	
		rows[0].text = '神話之鳥 再現戰地馬祖';
		rows[0].link = 'today-weekly1.htm';
																											
		rows[1].text = '活跳跳海鮮 炎夏鮮滋味';
		rows[1].link = 'today-weekly2.htm';
																											
		rows[2].text = '墨西哥莎莎醬<br>嗆辣超夠勁';
		rows[2].link = 'today-weekly3.htm';
																											
		rows[3].text = '省電吹冷氣 好招大彙集';
		rows[3].link = 'today-weekly4.htm';
																											
		rows[4].text = '愛犬走失！全民搜查線';
		rows[4].link = 'today-weekly5.htm';
																											
		rows[5].text = 'missing排行榜<br>警覺心提升，走失危機不近身!';
		rows[5].link = 'today-weekly6.htm';
																											
		rows[6].text = '奉行最適合自己的搜尋模式<br>掌握黃金時效';
		rows[6].link = 'today-weekly7.htm';
																											
		rows[7].text = '一目了然 簡潔詳細<br>零缺點！ 正確尋狗海報設計';
		rows[7].link = 'today-weekly8.htm';
																											
		rows[8].text = '高樹小吃 吃在地人情老滋味';
		rows[8].link = 'today-weekly9.htm';
																											
		rows[9].text = '降溫好幫手<br>藺草出招 涼啊涼一夏';
		rows[9].link = 'today-weekly10.htm';
																											
		rows[10].text = '慢性病患保健之道';
		rows[10].link = 'today-weekly11.htm';
																											
		rows[11].text = 'Should We Dance？來跳舞吧！';
		rows[11].link = 'today-weekly12.htm';
																											
	}
	menu = null;
}
if (showHouse)
{
	menu = getMenu('house');
	menu.layer = 14;
	menu.menuLayer = 0;
	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';
}