ÿþv a r   L a s t L e f t I D   =   " " ;  
 / / D o M e n u ( " C h i l d M e n u 1 " )  
 D o M e n u ( " C h i l d M e n u " + D K C D )  
 f u n c t i o n   m e n u F i x ( )   {  
   v a r   o b j   =   d o c u m e n t . g e t E l e m e n t B y I d ( " n a v " ) . g e t E l e m e n t s B y T a g N a m e ( " l i " ) ;  
    
   f o r   ( v a r   i = 0 ;   i < o b j . l e n g t h ;   i + + )   {  
     {  
       t h i s . c l a s s N a m e + = ( t h i s . c l a s s N a m e . l e n g t h > 0 ?   "   " :   " " )   +   " s f h o v e r " ;  
     }  
     o b j [ i ] . o n M o u s e D o w n = f u n c t i o n ( )   {  
       t h i s . c l a s s N a m e + = ( t h i s . c l a s s N a m e . l e n g t h > 0 ?   "   " :   " " )   +   " s f h o v e r " ;  
     }  
     o b j [ i ] . o n M o u s e U p = f u n c t i o n ( )   {  
       t h i s . c l a s s N a m e + = ( t h i s . c l a s s N a m e . l e n g t h > 0 ?   "   " :   " " )   +   " s f h o v e r " ;  
     }  
     o b j [ i ] . o n m o u s e o u t = f u n c t i o n ( )   {  
       t h i s . c l a s s N a m e = t h i s . c l a s s N a m e . r e p l a c e ( n e w   R e g E x p ( " (   ? | ^ ) s f h o v e r \ \ b " ) ,   " " ) ;  
     }  
   }  
 }  
 f u n c t i o n   D o M e n u ( e m i d )  
 {  
   v a r   o b j   =   d o c u m e n t . g e t E l e m e n t B y I d ( e m i d ) ;    
   o b j . c l a s s N a m e   =   ( o b j . c l a s s N a m e . t o L o w e r C a s e ( )   = =   " e x p a n d e d " ? " c o l l a p s e d " : " e x p a n d e d " ) ;  
   i f ( ( L a s t L e f t I D ! = " " ) & & ( e m i d ! = L a s t L e f t I D ) )  
   {  
         d o c u m e n t . g e t E l e m e n t B y I d ( L a s t L e f t I D ) . c l a s s N a m e   =   " c o l l a p s e d " ;  
   }  
   L a s t L e f t I D   =   e m i d ;  
 }  
  
 f u n c t i o n   G e t M e n u I D ( )  
 {  
   v a r   M e n u I D = " " ;  
   v a r   _ p a r a m S t r   =   n e w   S t r i n g ( w i n d o w . l o c a t i o n . h r e f ) ;  
   v a r   _ s h a r p P o s   =   _ p a r a m S t r . i n d e x O f ( " # " ) ;  
    
   i f   ( _ s h a r p P o s   > =   0   & &   _ s h a r p P o s   <   _ p a r a m S t r . l e n g t h   -   1 )  
   {  
     _ p a r a m S t r   =   _ p a r a m S t r . s u b s t r i n g ( _ s h a r p P o s   +   1 ,   _ p a r a m S t r . l e n g t h ) ;  
   }  
   e l s e  
   {  
     _ p a r a m S t r   =   " " ;  
   }  
    
   i f   ( _ p a r a m S t r . l e n g t h   >   0 )  
   {  
     v a r   _ p a r a m A r r   =   _ p a r a m S t r . s p l i t ( " & " ) ;  
     i f   ( _ p a r a m A r r . l e n g t h > 0 )  
     {  
       v a r   _ p a r a m K e y V a l   =   _ p a r a m A r r [ 0 ] . s p l i t ( " = " ) ;  
       i f   ( _ p a r a m K e y V a l . l e n g t h > 0 )  
       {  
         M e n u I D   =   _ p a r a m K e y V a l [ 1 ] ;  
       }  
     }  
   }  
    
   i f ( M e n u I D ! = " " )  
   {  
         D o M e n u ( M e n u I D ) ;  
   }  
 }  
 / / G e t M e n u I D ( ) ;    
 / / m e n u F i x ( ) ;  
 
