    var _Timer;
   
    function openMenu( item){

        var xmldom, xmlroot;
        var serialno, subject;
        var _menu;
        var layer;
        var html;
        var total;
        var i;
    
        clearTimeout( _Timer);
        
        _menu = GetPosition( document.getElementById( 'menu_' + item));
       
        xmldom = LoadMenuXml();
        
        xmlroot = xmldom.selectSingleNode('./root/result/item[@category=\'' + item + '\']');
        
        html = '';
        
        total = 0;
        
        if( xmlroot != null) total = xmlroot.selectNodes('./single').length;
        
        if( total > 0){
            
            html += '   <table border="0" cellpadding="5" cellspacing="1" bgcolor="#1C6BAF">\n';
            html += '    <tr>\n';
            html += '     <td width="100%" align="center" valign="top" bgcolor="#E3ECF5">\n';
            html += '      <table border="0" cellpadding="2" cellspacing="2">\n'; 
            
            for( i = 0; i < total; i ++){

                serialno = xmlroot.selectNodes('./single/serialno')[i].firstChild.nodeValue;
                subject = xmlroot.selectNodes('./single/subject')[i].firstChild.nodeValue;

                html += '         <tr>\n'; 
                html += '          <td width="11" align="right" valign="top"><img src="./images/arrow_blue.gif"></td>\n'; 
                html += '          <td class="black_12x"><a href="article_view.asp?sn=' + serialno + '" class="black_lnk">' + subject + '</a></td>\n'; 
                html += '         </tr>\n'; 
                
            }
            
            html += '      </table>\n'; 
            html += '     </td>\n';
            html += '    </tr>\n';
            html += '   </table>\n';
            
        }
        
        if( document.getElementById('sub-menu')) document.body.removeChild( document.getElementById('sub-menu'));
        
        layer = document.createElement('div');
        
        layer.setAttribute( 'id', 'sub-menu');
        layer.style.position = 'absolute';
        layer.style.top = ( _menu.top + 25) + 'px';
        layer.style.left = ( _menu.left + 1) + 'px';
        layer.innerHTML = html;

		layer.onmouseover = function(){
		    			
			clearTimeout( _Timer);
			
			this.style.display = 'block';
			
		}
		
		layer.onmouseout = function(){
		
			this.style.display = 'none';
		
		}

        document.body.appendChild( layer);
        
    }
    
    function closeMenu(){
        
        _Timer = setTimeout( 'document.getElementById(\'sub-menu\').style.display = \'none\';', 100);
        
    }
   
    function LoadMenuXml(){

        var xmldom;
        
        if( window.event) xmldom = new ActiveXObject('microsoft.XMLDOM');
        
        else xmldom = document.implementation.createDocument( '', '', null);

        xmldom.async = false;
        
        xmldom.load( './xml/xml_article_top_list.xml');
        
        return xmldom;
        
    }    

    function Point( _left, _top){
    
¡@¡@    this.left = _left;
¡@¡@    this.top = _top; 
        
    }
    
    function GetPosition( _object){
        
        var iCurrent = new Point( _object.offsetLeft, _object.offsetTop);
        var iWork = new Point( 0, 0);
        
        if( _object.offsetParent.tagName != 'BODY'){
          
            iWork = GetPosition( _object.offsetParent);  
            
            iCurrent.left += iWork.left;
            iCurrent.top += iWork.top;
            
        }
        
        return iCurrent;
        
    }
