//===========================================================================
//基本設定
//==================== 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(9);
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';
																										
	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';
																										
}
menu = null;

menu = getMenu('p');
menu.layer = 2;
menu.menuLayer = 0;
menu.rows = new Array(9);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '六四17周年 民運人士：經濟成北京極權藉口';
	rows[0].link = 'today-p1.htm';
																										
	rows[1].text = '游錫&#22531;：積極投入中國維權運動';
	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 = '享壽105歲 前立法院長倪文亞病逝';
	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 = '王世堅放話：謝長廷考慮參選';
	rows[7].link = 'today-p8.htm';
																										
	rows[8].text = '竹北生醫園區風波 何煖軒︰專區地價 已漲近三倍';
	rows[8].link = 'today-p9.htm';
																										
}
menu = null;

menu = getMenu('int');
menu.layer = 4;
menu.menuLayer = 0;
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-int1.htm';
																										
	rows[1].text = "不必手術！ 西班牙擬放寬性別登記";
	rows[1].link = 'today-int2.htm';
																										
	rows[2].text = "名譽官司 李文和5千萬落袋";
	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 = "27000年前拓手印";
	rows[7].link = 'today-int8.htm';
																										
	rows[8].text = "巨蟒男童情深";
	rows[8].link = 'today-int9.htm';
																										
	rows[9].text = "《中日對照讀新聞》&#12471;&#12459;肉料理&#12434;名物&#12395;…東京&#12539;&#22885;多摩町 鹿肉料理變身地方名產、東京奧多摩町";
	rows[9].link = 'today-int10.htm';
																										
	rows[10].text = "《中英對照讀新聞》Parody of Japan anthem spreading as protest 諷刺版日本國歌在網路上流傳以示抗議";
	rows[10].link = 'today-int11.htm';
																										
}
menu = null;

menu = getMenu('so');
menu.layer = 3;
menu.menuLayer = 0;
menu.rows = new Array(14);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '關鍵76分鐘 楓港拍到紅奧迪';
	rows[0].link = 'today-so1.htm';
																										
	rows[1].text = '羈押抗告 最快明天有結果';
	rows[1].link = 'today-so2.htm';
																										
	rows[2].text = '看守所 泰安好吃好睡';
	rows[2].link = 'today-so3.htm';
																										
	rows[3].text = '2人廝殺選里長 雙雙進牢房';
	rows[3].link = 'today-so4.htm';
																										
	rows[4].text = '擒歹徒 保全研發「捕捉網」';
	rows[4].link = 'today-so5.htm';
																										
	rows[5].text = '澳仔漁港潛水意外 2死1傷';
	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';
																										
	rows[12].text = '生命 走一趟醫院 學子深刻體驗';
	rows[12].link = 'today-so13.htm';
																										
	rows[13].text = '開智慧轉大人 跪謝父母恩';
	rows[13].link = 'today-so14.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 = '大學生發起苦行環島 為台灣祈福';
	rows[0].link = 'today-life1.htm';
																										
	rows[1].text = '印尼震災逾6千人亡 紅十字會一週僅募135萬';
	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 = '南市視障考生榜首 小貝多芬 如願上南一中';
	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 = '解字迷爆料 草書字畫有初解';
	rows[7].link = 'today-life8.htm';
																										
	rows[8].text = '24獨木舟勇士 成功橫渡基隆嶼';
	rows[8].link = 'today-life9.htm';
																										
}
menu = null;

menu = getMenu('sp');
menu.layer = 10;
menu.menuLayer = 0;
menu.rows = new Array(11);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '《2006世界盃足球賽》E組-「義」氣風發 F組-魔幻森「巴」';
	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 = '《台灣希望巡迴賽》守屈一指 林吉祥封王';
	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 = '《LPGA巡迴賽ShopRite菁英賽》洪沁慧 職業最低桿';
	rows[6].link = 'today-sp7.htm';
																										
	rows[7].text = '《南韓桌球公開賽》默契佳 張吳配第三';
	rows[7].link = 'today-sp8.htm';
																										
	rows[8].text = '獅灌9連勝';
	rows[8].link = 'today-sp9.htm';
																										
	rows[9].text = '鯨戒9止敗';
	rows[9].link = 'today-sp10.htm';
																										
	rows[10].text = '基特歸隊 馬上建功';
	rows[10].link = 'today-sp11.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 = '美光、海力士 涉壟斷DRAM價格';
	rows[0].link = 'today-e1.htm';
																										
	rows[1].text = '紐約期油漲至72.33美元';
	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 = '網通業不缺席 參展拚本事';
	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(8);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = 'Web2.0當紅 業者卡位戰';
	rows[0].link = 'today-stock1.htm';
																										
	rows[1].text = '雙卡衝擊高峰 可能在6、7月';
	rows[1].link = 'today-stock2.htm';
																										
	rows[2].text = '卡債協商繳款率 上月達85%';
	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';
																										
	rows[6].text = '生技股價 十年新低';
	rows[6].link = 'today-stock7.htm';
																										
	rows[7].text = '股債平衡投資 報酬率不差';
	rows[7].link = 'today-stock8.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(13);
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 = '南拳接周董地盤 踢Jolin奪冠';
	rows[2].link = 'today-show3.htm';
																										
	rows[3].text = '王怡仁 自認比AV女優美';
	rows[3].link = 'today-show4.htm';
																										
	rows[4].text = '何以奇 自家旅館打工沒特權';
	rows[4].link = 'today-show5.htm';
																										
	rows[5].text = '賀一航拾金不昧 寧背債不貪財';
	rows[5].link = 'today-show6.htm';
																										
	rows[6].text = '阿亮肉搏屈中恆 阿Ken爆奶拆擂台';
	rows[6].link = 'today-show7.htm';
																										
	rows[7].text = '休葛蘭偷吃舊愛赫莉 潔蜜瑪搥心';
	rows[7].link = 'today-show8.htm';
																										
	rows[8].text = '裘莉女兒小嘴 吸51萬鑽石奶嘴';
	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 = '姜至奐2度來台夢碎';
	rows[11].link = 'today-show12.htm';
																										
	rows[12].text = '東洋銀色姊弟戀 愛火熱不婚頭';
	rows[12].link = 'today-show13.htm';
																										
}
menu = null;

menu = getMenu('c');
menu.layer = 5;
menu.menuLayer = 0;
menu.rows = new Array(2);
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';
																
}
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(8);
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 = '謝明海的GBSY 讓台北變好';
	rows[3].link = 'today-taipei4.htm';
																										
	rows[4].text = '捷運板土線 運量達20萬人次';
	rows[4].link = 'today-taipei5.htm';
																										
	rows[5].text = '30噸巨石毀屋砸車 幸無傷亡';
	rows[5].link = 'today-taipei6.htm';
																										
	rows[6].text = '輔大抓流浪狗 學生不忍校園掀波';
	rows[6].link = 'today-taipei7.htm';
																										
	rows[7].text = '啟用到落成拖4月 烘內派出所惹爭議';
	rows[7].link = 'today-taipei8.htm';
																										
}
menu = null;

menu = getMenu('north');
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-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 = '老被冒名行騙 宜地院宣導反詐';
	rows[4].link = 'today-north5.htm';
																										
	rows[5].text = '警伯速擒機車賊 失主感激';
	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 = 13;
menu.parentMenu = 'region';
menu.menuLayer = 1;
menu.rows = new Array(10);
with (menu)
{
	for (i=0; i<rows.length; i++)
		rows[i] = new Object();
																
	rows[0].text = '真貸款假投資 吸金逾2億元';
	rows[0].link = 'today-center1.htm';
																										
	rows[1].text = '雲210線 1小時2車禍1死1傷';
	rows[1].link = 'today-center2.htm';
																										
	rows[2].text = '少年無照飆車 爸媽網站亮名';
	rows[2].link = 'today-center3.htm';
																										
	rows[3].text = '為養子女行竊 老母吐槽拒保';
	rows[3].link = 'today-center4.htm';
																										
	rows[4].text = '醉駕駛醉騎士對撞 都送辦';
	rows[4].link = 'today-center5.htm';
																										
	rows[5].text = '涉嫌買票 葉清南10萬交保';
	rows[5].link = 'today-center6.htm';
																										
	rows[6].text = '性侵學生 老師上訴被駁回';
	rows[6].link = 'today-center7.htm';
																										
	rows[7].text = '偷嘗禁果 小男友挨告函送';
	rows[7].link = 'today-center8.htm';
																										
	rows[8].text = '財務糾紛 偷千萬機械送辦';
	rows[8].link = 'today-center9.htm';
																										
	rows[9].text = '擔心入獄 男子走上不歸路';
	rows[9].link = 'today-center10.htm';
																										
}
menu = null;

menu = getMenu('south');
menu.layer = 14;
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 = '豪大雨 三地門、霧台沿線坍方';
	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 = '認養學童 與認養人喜相逢';
	rows[3].link = 'today-south4.htm';
																										
	rows[4].text = '律師要分手 女友告他搶奪';
	rows[4].link = 'today-south5.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 = '魚池小吃 驚艷好滋味';
		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 = '新嫁娘亮麗一整天 新娘祕書巧手打點';
		rows[5].link = 'today-weekly6.htm';
																											
		rows[6].text = '新人選訂喜餅 全攻略';
		rows[6].link = 'today-weekly7.htm';
																											
		rows[7].text = '訂婚喜餅禮俗 知多少？';
		rows[7].link = 'today-weekly8.htm';
																											
		rows[8].text = '快拿筆記下來 完美婚宴A計劃';
		rows[8].link = 'today-weekly9.htm';
																											
		rows[9].text = '概念新潮流 超實用結婚禮物清單';
		rows[9].link = 'today-weekly10.htm';
																											
		rows[10].text = '優遊鶯歌陶瓷鄉 拉坏樂陶陶';
		rows[10].link = 'today-weekly11.htm';
																											
		rows[11].text = '在地美味料理 鶯得饕客心';
		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';
}
