document.write("<link href='style.css' rel='stylesheet' type='text/css'>");



var l=new Array()

a='<span class="menuitems"><a href="';

b='</a></span>';

l[0]=a+'#">F1'+b

l[0]+=a+'#">F2'+b

l[0]+=a+'#">F3'+b



l[1]=a+'">Focus News'+b

l[1]+=a+'http://cnn.com">F1'+b

l[1]+=a+'http://abcnews.com">F2'+b

l[1]+=a+'http://abcnews.com">F3'+b

l[1]+=a+'http://abcnews.com">(fixed text link)'+b



l[2]=a+'">Mail Box'+b

l[2]+=a+'">ADSL'+b

l[2]+=a+'">Community'+b

l[2]+=a+'">Set to be homepage'+b

l[2]+=a+'">Service index'+b

l[2]+=a+'">(fixed Text link)'+b



l[3]=a+'http://www.hinet.net/ri/games.html">遊戲'+b

l[3]+=a+'http://www.hinet.net/ri/hichannel.html">影視'+b

l[3]+=a+'http://www.hinet.net/ri/music.html">音樂'+b

l[3]+=a+'http://www.hinet.net/ri/broad.html">廣播'+b

l[3]+=a+'http://www.hinet.net/ri/japan.html">哈日'+b

l[3]+=a+'http://www.hinet.net/ri/hiair.html">簡訊圖鈴'+b



l[4]=a+'../music/music1.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">華語'+b

l[4]+=a+'../music/music2.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">西洋'+b

l[4]+=a+'../music/music3.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">日韓'+b

l[4]+=a+'../music/music4.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">影視'+b

l[4]+=a+'../music/music5.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">廣告'+b

l[4]+=a+'../music/music6.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">古典'+b

l[4]+=a+'../music/music7.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">爵士'+b



l[5]=a+'../member/join.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">訂閱/取消'+b

l[5]+=a+'../member/buy.htm""><img src=images/icon.gif border=0><font color="#000000" size="2">我的購物車'+b

l[5]+=a+'../member/buy_list.htm"><img src=images/icon.gif border=0><font color="#000000" size="2">我的消費紀錄'+b

l[5]+=a+'../member/join.htm""><img src=images/icon.gif border=0><font color="#000000" size="2">新手上路'+b

l[5]+=a+'../member/join.htm""><img src=images/icon.gif border=0><font color="#000000" size="2">小幫手'+b



var ie4=document.all&&navigator.userAgent.indexOf("Opera")==-1

var ns6=document.getElementById&&!document.all

var ns4=document.layers



function showmenu2(e,which,mywidth){

startHTML = '<TABLE border=0 bordercolor=#000000 cellspacing=0 cellpadding=0 width='+ mywidth +'><TR><TD colspan=3 align=center background=images/upl.gif><img src=images/upm.gif border=0></TD></TR><tr><TD background=images/LR.gif></TD><td class="whitenounderline" bgcolor=#FFFFFF> ';

endHTML = '</td><TD background=images/LR.gif></TD></tr><TR><TD align=center background=images/downM.gif colspan=3><img src=images/downM.gif border=0></TD></TR></table>';

if (!document.all&&!document.getElementById&&!document.layers)

return

clearhidemenu()

menuobj=ie4? document.all.popmenu : ns6? document.getElementById("popmenu") : ns4? document.popmenu : ""

menuobj.thestyle=(ie4||ns6)? menuobj.style : menuobj

menuobj.thestyle=(ie4||ns6)? menuobj.style : menuobj

if (ie4||ns6)

menuobj.innerHTML=startHTML + which + endHTML;

else{

menuobj.document.write('<layer name=gui bgColor=#FFFFFF width=80 onmouseover="clearhidemenu()" onmouseout="hidemenu()">'+which+'</layer>')

menuobj.document.close()

}

menuobj.contentwidth=(ie4||ns6)? menuobj.offsetWidth : menuobj.document.gui.document.width

menuobj.contentheight=(ie4||ns6)? menuobj.offsetHeight : menuobj.document.gui.document.height

eventX=ie4? event.clientX : ns6? e.clientX : e.x

eventY=ie4? event.clientY : ns6? e.clientY : e.y

//Find out how close the mouse is to the corner of the window

var rightedge=ie4? document.body.clientWidth-eventX : window.innerWidth-eventX

var bottomedge=ie4? document.body.clientHeight-eventY : window.innerHeight-eventY

//if the horizontal distance isn't enough to accomodate the width of the context menu

if (rightedge<menuobj.contentwidth)

//move the horizontal position of the menu to the left by it's width

menuobj.thestyle.left=ie4? document.body.scrollLeft+eventX-((menuobj.contentwidth)/2) : ns6? window.pageXOffset+eventX-menuobj.contentwidth : eventX-menuobj.contentwidth



else

//position the horizontal position of the menu where the mouse was clicked

menuobj.thestyle.left=ie4? document.body.scrollLeft+eventX-(menuobj.contentwidth/2) : ns6? window.pageXOffset+eventX : eventX



//same concept with the vertical position

if (bottomedge<menuobj.contentheight)

menuobj.thestyle.top=ie4? document.body.scrollTop+eventY-menuobj.contentheight : ns6? window.pageYOffset+eventY-menuobj.contentheight : eventY-menuobj.contentheight

else

menuobj.thestyle.top=ie4? document.body.scrollTop+event.clientY : ns6? window.pageYOffset+eventY : eventY

menuobj.thestyle.visibility="visible"



return false

}













function contains_ns6(a, b) {

//Determines if 1 element in contained in another- by Brainjar.com

while (b.parentNode)

if ((b = b.parentNode) == a)

return true;

return false;

}



function hidemenu(){

if (window.menuobj)

menuobj.thestyle.visibility=(ie4||ns6)? "hidden" : "hide"

}



function dynamichide(e){

if (ie4&&!menuobj.contains(e.toElement))

hidemenu()

else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))

hidemenu()

}



function delayhidemenu(){

if (ie4||ns6||ns4)

delayhide=setTimeout("hidemenu()",500)

}



function clearhidemenu(){

if (window.delayhide)

clearTimeout(delayhide)

}



function highlightmenu(e,state){

if (document.all)

source_el=event.srcElement

else if (document.getElementById)

source_el=e.target

if (source_el.className=="menuitems"){

source_el.id=(state=="on")? "mouseoverstyle" : ""

}

else{

while(source_el.id!="popmenu"){

source_el=document.getElementById? source_el.parentNode : source_el.parentElement

if (source_el.className=="menuitems"){

source_el.id=(state=="on")? "mouseoverstyle" : ""

}

}

}

}



if (ie4||ns6)

document.onclick=hidemenu



function setHome() {

var agent = navigator.userAgent;

if( agent.indexOf("MSIE") != -1){var strVersion = navigator.appVersion; var pos = strVersion.indexOf("MSIE");strVersion = strVersion.substring(pos+4,strVersion.length);var version = parseInt(strVersion);if(version >= 5){oHomePage.style.behavior='url(#default#homepage)';oHomePage.setHomePage('http://www.hinet.net/');}}}









function mbr_init() {

if(getCookie("otpw")==null)

{

mbrStr='<table border="0" cellspacing="0" cellpadding="0"> <tr> <td> <table width="65" border="0" cellpadding="0" cellspacing="0" height="55" class="stnobold"> <tr> <td>．<a href="http://www.hinet.net/ri/webmail.html" class="stnobold">我的信箱</a></td> <td>&nbsp;</td> </tr> <tr> <td>．<a href="http://www.hinet.net/ri/myweb.html" class="stnobold">個人網頁</a></td> <td>&nbsp;</td> </tr> <tr> <td>．<a href="http://www.hinet.net/ri/member.html" class="stnobold">會員中心</a></td> <td>&nbsp;</td> </tr> </table></td> <td><img src="images/home_03.gif" width="10" height="10"></td> <td align="center"> <table width="50" border="0"  class="stnobold"> <tr> <td>．<a class="stnobold2" href="http://www.hinet.net/ri/hichannel.html">影視</a></td> </tr> <tr> <td>．<a class="stnobold2" href="http://www.hinet.net/ri/games.html">遊戲</a></td> </tr> <tr> <td align="center"><a class="stnobold1" href="http://member.hinet.net/MemberCenter/Login.jsp">登入</a></td> </tr> </table></td> </tr> </table> <table width="128" border="0" cellpadding="0" cellspacing="0" height="34"> <tr> <td><a class="stnobold" href="http://member.hinet.net/centerimages/ebook_index.htm">體驗不可思議的閱讀樂趣</a><br></td> </tr> </table>';

document.write (mbrStr);

}

else

{

mbrStr='<table border="0" cellspacing="0" cellpadding="0"> <tr> <td> <table width="65" border="0" cellpadding="0" cellspacing="0" height="55" class="stnobold"> <tr> <td>．<a href="http://www.hinet.net/ri/webmail.html" class="stnobold">我的信箱</a></td> <td>&nbsp;</td> </tr> <tr> <td>．<a href="http://www.hinet.net/ri/myweb.html" class="stnobold">個人網頁</a></td> <td>&nbsp;</td> </tr> <tr> <td>．<a href="http://www.hinet.net/ri/member.html" class="stnobold">會員中心</a></td> <td>&nbsp;</td> </tr> </table></td> <td><img src="images/home_03.gif" width="10" height="10"></td> <td align="center"> <table width="50" border="0"  class="stnobold"> <tr> <td>．<a class="stnobold2" href="http://www.hinet.net/ri/hichannel.html">影視</a></td> </tr> <tr> <td>．<a class="stnobold2" href="http://www.hinet.net/ri/games.html">遊戲</a></td> </tr> <tr> <td align="center"><a class="stnobold" href="http://member.hinet.net/MemberCenter/Logout.jsp">登出</a></td> </tr> </table></td> </tr> </table> <table width="128" border="0" cellpadding="0" cellspacing="0" height="34"> <tr> <td><a class="stnobold" href="http://member.hinet.net/MemberCenter/index.jsp">會員獨有魔戒限量珍藏版撲克牌<br></td> </tr> </table>';

document.write (mbrStr);

}

}

function mbr_sayHi(){

if(getCookie("otpw")==null)

{

//登入前 ' Hi! '

mbrStr='Hi!';

document.write (mbrStr);

}

else

{

//登入後 ' Hi! xxxxx '

mbrStr='Hi!' + getCookie('MemberInformation');

document.write (mbrStr);

}

}

function getCookie(name)

{

var begin;

var end;

var cname=name+"=";

var dc=document.cookie;

if(dc.length>0)

{

begin=dc.indexOf(cname);

if(begin!=-1)

{

begin+=cname.length;

end=dc.indexOf(";",begin);

if(end==-1)

end=dc.length;

return unescape(dc.substring(begin,end));

}

}

return null;

}





function MM_reloadPage(init) {  //reloads the window if Nav4 resized

  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {

    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}

  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();

}

MM_reloadPage(true);



function MM_jumpMenu(targ,selObj,restore){ //v3.0

  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");

  if (restore) selObj.selectedIndex=0;

}



function MM_findObj(n, d) { //v4.01

  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {

    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}

  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];

  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);

  if(!x && d.getElementById) x=d.getElementById(n); return x;

}



function MM_showHideLayers() { //v6.0

  var i,p,v,obj,args=MM_showHideLayers.arguments;

  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];

    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }

    obj.visibility=v; }

}



function MM_swapImgRestore() { //v3.0

  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;

}



function MM_preloadImages() { //v3.0

  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();

    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)

    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}

}



function MM_swapImage() { //v3.0

  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)

   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}

}



function MM_openBrWindow(theURL,winName,features) { //v2.0

  window.open(theURL,winName,features);

}



