ÿþ/ *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *    
   *   S e z i o n e   p e r s o n a l i z z a b i l e . .  
   *   M o d i f i c a r e   l e   v a r i a b i l i   e   g l i   a r r a y   s e g u e n t i   p e r   a d a t t a r e   i l   m e n u   a l   p r o p r i   s i t o .  
   *   L ' u l t i m a   v o c e   d i   q u e s t o   m e n u   e '   u n   l i n k   a   J s D i r ,   s e   c r e d e t e   p o t e t e   t o g l i e r l o ,   m a   i n   t a l   c a s o   v i   p r e g h i a m o  
   *   d i   l a s c i a r e   i l   r i f e r i m e n t o   d e l l a   r i g a   s e g u e n t e . . .   d o p o t u t t o   n o n   l ' a v e t e   p a g a t o   n u l l a ,   q u i n d i . . .   c h e   v i   c o s t a ?   : - )  
   *  
   *   U l t i m o   a g g i o r n a m e n t o :   1 6   G e n n a i o   2 0 0 6  
   *  
   *   Q u e s t o   m e n u   e '   ( C ) 2 0 0 1   w e b m a s t e r A T j s d i r . c o m   -   L o   s c r i p t   e '   r e p e r i b i l e   a l   s i t o   h t t p : / / w w w . j s d i r . c o m   -   J a v a S c r i p t   D i r e c t o r y  
   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   * /  
 v a r   r o n = " # 3 3 C C C C " ;   / /   C o l o r e   a l   M o u s e O v e r  
 v a r   r o f f = " # E A F F F F " ;   / /   C o l o r e   d i   d e f a u l t  
 v a r   l e f t m a r g i n = 0 ;   / /   D i s t a n z a   d a l   m a r g i n e   s i n i s t r o   d e l l a   p a g i n a   (   - - - >   v .   c o m m e n t o   a l l a   r i g a   5 7 )  
 v a r   t o p m a r g i n = 1 2 7 ;   / /   D i s t a n z a   d a l   m a r g i n e   s u p e r i o r e   d e l l a   p a g i n a  
 v a r   l a r g o = 1 1 0 ;   / /   L a r g h e z z a   d e i   l a y e r s ,   q u i n d i   d i s t a n z a   ( o r i z z o n t a l e )   f r a   i   s o t t o m e n u  
  
 v a r   H o m e   =   t r u e ;   / /   S e t t a r e   a   " f a l s e "   s e   n o n   s i   d e s i d e r a   i l   l i n k   a l l ' h o m e p a g e  
 v a r   H o m e L i n k   =   " h t t p : / / w w w . p s i c h i t a l i a . i t / i n d e x . h t m " ;   / /   U R L   d e l l a   h o m e p a g e  
 v a r   H o m e T e x t   =   " H o m e " ;   / /   T e s t o   d e l   l i n k   a l l a   h o m e p a g e  
 v a r   H o m e W i d t h   =   5 0 ;   / /   L a r g h e z z a   d e l   l i v e l l o   c h e   c o n t i e n e   i l   t a s t o   a l l a   h o m e p a g e .   ( s e   " H o m e "   v i e n e   i m p o s t a t o   a   " f a l s e "   v i e n e   a z z e r a t o .  
  
 / *   L ' a r r a y   s e g u e n t e   c o n t i e n e   i   t e s t i   c h e   v e r r a n n o   v i s u a l i z z a t i   d a l   m e n u .  
   *   N e l l ' e s e m p i o   ( i l   m e n u   d i   J s D i r )   t r o v a t e   q u a t t r o   e l e m e n t i   d e l l ' a r r a y   " v o c i "   c o r r i s p o n d e n t i   a l l e   q u a t t r o   v o c i   d e l   m e n u   p r i n c i p a l e  
   *   I l   p r i m o   e l e m e n t o   d e g l i   a r r a y   e '   i l   n o m e   d e l   m e n u ,   g l i   e l e m e n t i   s u c c e s s i v i   s o n o   i   l i n k s   c o n t e n u t i   n e l   s i n g o l o   m e n u .  
   *   I l   t a s t o   " H o m e "   n o n   c o m p a r e   i n   q u e s t o   a r r a y   p e r c h e '   v i e n e   i n s e r i t o   d i   d e f a u l t   c o m e   p r i m o   e l e m e n t o   * /  
 v a r   v o c i = n e w   A r r a y ( ) ;  
 	 v o c i [ 0 ] = n e w   A r r a y ( " S e g n a l a c i " ) ;  
 	 v o c i [ 1 ] = n e w   A r r a y ( " I s c r i v i t i   a r e a " ,   " P s i c o l o g i c a " ,   " S o c i a l e " ) ;  
  
 / *   Q u e s t o   a r r a y   c o n t i e n e   i n v e c e   i   l i n k s   c h e   s a r a n n o   a p e r t i   d a l l e   s i n g o l e   v o c i   d e i   s o t t o m e n u .  
   *   I n   q u e s t a   n u o v a   v e r s i o n e   d e l   m e n u   (   0 9   D i c   2 0 0 2   )   e '   p o s s i b i l e   s p e c i f i c a r e   u n   l i n k   a n c h e   p e r   l a   v o c e   p r i n c i p a l e   d e l   m e n u   * /  
 v a r   l i n k s = n e w   A r r a y ( ) ;  
 	 l i n k s [ 0 ] = n e w   A r r a y ( " h t t p : / / w w w . p s i c h i t a l i a . i t / P s i 2 / D e s / C o n t a t t i . h t m " )  
 	 l i n k s [ 1 ] = n e w   A r r a y ( " # " ,   " h t t p : / / w w w . p s i c h i t a l i a . i t / P s i 2 / D e s / I s c r i v i t i A r e a P s i . h t m " ,   " h t t p : / / w w w . p s i c h i t a l i a . i t / P s i 2 / D e s / I s c r i v i t i A r e a S o c . h t m " )  
  
 / / 	 l i n k s [ 3 ] = n e w   A r r a y ( " / " ,   " # " ,   " # " ,   " # " ,   " # " ,   " h t t p : / / w w w . " )  
  
 / *   Q u e s t o   a r r a y   c o n t i e n e   i   t a r g e t   d e i   l i n k s  
   *   A   p a r t i r e   d a l   1 0   O t t o b r e   2 0 0 4   e '   i n   g r d o   d i   g e s t i r e   f r a m e s ,   f i n e s t r e   e   p o p - u p .  
   *   L a   p r i m a   p a r t e   d e l l a   s t r i n g a   ( " n o m e "   o   l e t t e r a + | )     i n d i c a   i l   t i p o   d i   d e s t i n a z i o n e :  
   *       " w i n "   s t a   p e r   " n u o v a   f i n e s t r a " :   a n a l o g o   a l   t a r g e t = ' _ b l a n k '   d i   u n   n o r m a l e   l i n k   A   H R E F  
   *       " s e l f "   a p r e   n e l l o   s t e s s o   f r a m e   i n   c u i   e '   c o n t e n u t o   i l   m e n u ,   a n a l o g o   a l   t a r g e t = " _ s e l f "   d i   u n   n o r m a l e   l i n k   A   H R E F  
   *       " t o p "   a p r e   i l   l i n k   s o s t i t e n d o   i l   f r a m e s e t ,   a n a l o g o   a l   t a r g e t = " _ t o p "   d i   u n   n o r m a l e   l i n k   A   H R E F  
   *       " p | "   s t a   p e r   p o p - u p ,   s e g u o n o   n e l l a   s t e s s a   s t r i n g a   l e   c o n s u e t e   i s t r u z i o n i   p e r   l a   f o r m a t t a z i o n e ,   a d   e s e m p i o   " p | w i d t h = 1 0 0 , h e i g h t = 1 0 0 , r e s i z a b l e = y e s "  
   *       " f | "   s t a   p e r   " i n   u n   f r a m e " ,   s e g u e   i l   n o m e   d e l   f r a m e   i n   c u i   a p r i r e   i l   l i n k ,   a d   e s e m p i o   " f | n o m e f r a m e " .  
   *    
   *   S e   n o n   v i e n e   r i c o n o s c i u t a   l a   s t r i n g a   d i   d e s t i n a z i o n e ,   i l   l i n k   v i e n e   a p e r t o   i n   m o d a l i t a '   " s e l f " ,   q u i n d i   s o s t i t u e n d o   l a   p a g i n a   i n   c u i   e '   c o n t e n u t o   i l   m e n u .  
   *    
   *   F o r s e   e '   u n   p o '   m a c c h i n o s o ,   m a   e v i t a   d i   d o v e r   g e s t i r e   u n   a l t r o   a r r a y   s o l o   p e r   p o t e r   s p e c i f i c a r e   i l   n o m e   d i   u n   e v e n t u a l e   f r a m e .   : - )  
   *    
   *   N e l l ' e s e m p i o   c h e   s e g u e :  
   *   -   i l   p r i m o   l i n k   v e n e   a p e r t o   i n   u n ' a l t r a   f i n e s t r a   d e l   b r o w s e r ;  
   *   -   i l   s e c o n d o   n e l l o   s t e s s o   f r a m e   d o v ' e '   c o n t e n u t o   i l   m e n u ;  
   *   -   i l   t e r z o   s o s t i t u i s c e   i l   f r a m e s e t  
   *   -   i l   q u a r t o   n e l   f r a m e   " c o n t e n u t i "  
   *   -   i l   q u i n t o   i n   u n a   p o p - u p   d i   3 0 0 x 4 0 0   p i x e l  
   *    
   *   t a r g e t s [ . . . ] = n e w   A r r a y ( " w i n " ,   " s e l f " ,   " t o p " ,   " f | c o n t e n u t i " ,   " p | w i d t h = 3 0 0 , h e i g h t = 4 0 0 " )  
   *    
   *   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   * /  
 v a r   t a r g e t s = n e w   A r r a y ( ) ;  
 	 t a r g e t s [ 0 ] = n e w   A r r a y ( " s e l f " )  
 	 t a r g e t s [ 1 ] = n e w   A r r a y ( " s e l f " ,   " s e l f " ,   " s e l f " )  
  
 / *   U l t i m o   a r r a y .  
   *   C o n t i e n e   i   t e s t i   c h e   s a r a n n o   v i s u a l i z z a t i   n e l l a   b a r r a   d i   s t a t o   d e l   b r o w s e r   q u a n d o   i l   m o u s e   e '   s o p r a   u n a   v o c e   d e l   m e n u     * /  
 v a r   w s t = n e w   A r r a y ( ) ;  
 	 w s t [ 0 ] = n e w   A r r a y ( " S e g n a l a c i   . . . " ) ;  
 	 w s t [ 1 ] = n e w   A r r a y ( " " ,   " I s c r i v i t i   i n   A r e a   P s i c o l o g i c a " ,   " I s c r i v i t i   i n   A r e a   S o c i a l e " ) ;  
  
 / *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *    
   *   F i n e   s e z i o n e   p e r s o n a l i z z a b i l e .  
   *   L e   r i g h e   c h e   s e g u o n o   c o s t i t u i s c o n o   i l   m e n u   v e r o   e   p r o p r i o .  
   *   L a   p e r s o n a l i z z a z i o n e   e '   c o n s i g l i a t a   s o l o   a   w e b m a s t e r   u n   p o '   e s p e r t i   d i   J a v a S c r i p t ,   a d   e c c e z i o n e   d e l l a   r i g a   e v i d e n z i a t a  
   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   *   * /  
 v a r   n n = d o c u m e n t . l a y e r s ? t r u e : f a l s e , N 6 = n a v i g a t o r . u s e r A g e n t . t o L o w e r C a s e ( ) . i n d e x O f ( " g e c k o " ) ! = - 1 ? t r u e : f a l s e , c o n t a = 0 , l a s t = 0 ;  
 v a r   o p = n a v i g a t o r . u s e r A g e n t . t o L o w e r C a s e ( ) . i n d e x O f ( " o p e r a " ) ! = - 1 ? t r u e : f a l s e  
 H o m e W i d t h = H o m e ? H o m e W i d t h : 0 ;  
 v a r   M e n u L e n g t h = H o m e W i d t h + l a r g o * v o c i . l e n g t h ;  
 v a r   B r o w s e r W i d t h = n n | | o p ? w i n d o w . i n n e r W i d t h : N 6 ? d o c u m e n t . w i d t h : d o c u m e n t . b o d y . c l i e n t W i d t h ;  
 l e f t m a r g i n = p a r s e I n t ( ( B r o w s e r W i d t h - M e n u L e n g t h ) / 2 ) ;   / /   C o m m e n t a r e   q u e s t a   r i g a   c o n   / /   a l l ' i n i z i o   s e   n o n   s i   d e s i d e r a   i   m e n u   a l   c e n t r o   d e l l a   p a g i n a ,   b e n s i '   n e l l a   p o s i z i o n e   d e f i n i t a   i n   " l e f t m a r g i n "  
  
 i f   ( n n )  
 	 {  
 	 i f   ( H o m e )  
 	 	 d o c u m e n t . w r i t e ( " < L A Y E R   N A M E = m t o p .   p o s i t i o n = a b s o l u t e   l e f t = " + l e f t m a r g i n + "   t o p = " + t o p m a r g i n + "   w i d t h = " + H o m e W i d t h + "   h e i g h t = 1 5   c l i p = 0 , 0 , " + H o m e W i d t h + " , 1 5   b g C o l o r = " + r o f f + "   v i s i b i l i t y = v i s i b l e   o n M o u s e O v e r = s h o w d e p s ( l a s t , f a l s e ) ; m r o l l ( ' m t o p . ' )   o n M o u s e O u t = u n m r o l l ( ' m t o p . ' )   C L A S S = m e n u N N b > & n b s p ; < A   H R E F = ' " + H o m e L i n k + " '   C L A S S = m e n u N N b > " + H o m e T e x t + " < / A > < / L A Y E R > " ) ;  
 	 f o r   ( i = 0 ; i < v o c i . l e n g t h ; i + + )  
 	 	 {  
 	 	 v a r   n = i ;  
 	 	 d o c u m e n t . w r i t e l n ( " < L A Y E R   N A M E = m t o p " + n + " .   p o s i t i o n = a b s o l u t e   l e f t = " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + "   t o p = " + t o p m a r g i n + "   w i d t h = " + l a r g o + "   h e i g h t = 1 5   c l i p = 0 , 0 , " + l a r g o + " , 1 5   b g C o l o r = " + r o f f + "   v i s i b i l i t y = v i s i b l e   o n M o u s e O v e r = M o s t r a M e n u ( " + i + " ) ; m r o l l ( ' m t o p " + i + " . ' ) ; c o n t a + +   o n M o u s e O u t = l a s t = " + i + " ; u n m r o l l ( ' m t o p " + i + " . ' ) ; c o n t a - - > < D I V   A L I G N = c e n t e r   C L A S S = m e n u N N b > & n b s p ; < A   H R E F = j a v a s c r i p t : m r o l l ( ' m t o p " + i + " . ' )   o n C l i c k = v a i ( ' " + l i n k s [ i ] [ 0 ] + " ' , " + i + " , 0 )   C L A S S = m e n u N N b > " + v o c i [ i ] [ 0 ] + " < / A > < / D I V > < / L A Y E R > " ) ;  
 	 	 f o r   ( l = 1 ; l < v o c i [ i ] . l e n g t h ; l + + )  
 / / 	 	 	 d o c u m e n t . w r i t e l n ( " < L A Y E R   N A M E = m d e p " + i + " . " + l + "   p o s i t i o n = a b s o l u t e   l e f t = " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + "   t o p = " + e v a l ( t o p m a r g i n + 1 5 * l ) + "   w i d t h = " + l a r g o + "   h e i g h t = 1 5   c l i p = 0 , 0 , " + l a r g o + " , 1 5   b g C o l o r = " + r o f f + "   v i s i b i l i t y = h i d d e n   o n M o u s e O v e r = m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a + +   o n M o u s e O u t = u n m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a - -     C L A S S = m e n u N N b > & n b s p ; < A   H R E F = j a v a s c r i p t : m r o l l ( ' m d e p " + n + " . " + l + " ' )   o n C l i c k = v a i ( ' " + l i n k s [ i ] [ l ] + " ' , " + i + " , " + l + " )   C L A S S = m e n u N N > " + v o c i [ i ] [ l ] + " < / A > < / L A Y E R > " ) ;  
 	 	 	 d o c u m e n t . w r i t e l n ( " < L A Y E R   N A M E = m d e p " + i + " . " + l + "   p o s i t i o n = a b s o l u t e   l e f t = " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + "   t o p = " + e v a l ( t o p m a r g i n + 1 5 * l ) + "   w i d t h = 1 7 0   h e i g h t = 1 5   c l i p = 0 , 0 , " + l a r g o + " , 1 5   b g C o l o r = " + r o f f + "   v i s i b i l i t y = h i d d e n   o n M o u s e O v e r = m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a + +   o n M o u s e O u t = u n m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a - -     C L A S S = m e n u N N b > & n b s p ; < A   H R E F = j a v a s c r i p t : m r o l l ( ' m d e p " + n + " . " + l + " ' )   o n C l i c k = v a i ( ' " + l i n k s [ i ] [ l ] + " ' , " + i + " , " + l + " )   C L A S S = m e n u N N > " + v o c i [ i ] [ l ] + " < / A > < / L A Y E R > " ) ;  
 	 	 }  
 	 }  
 	 e l s e  
 	 {  
 	 i f   ( H o m e )  
 	 	 d o c u m e n t . w r i t e ( " < d i v   i d = ' m t o p . '   s t y l e = \ " p o s i t i o n : a b s o l u t e ; l e f t : " + l e f t m a r g i n + " p x ; t o p : " + t o p m a r g i n + " p x ; w i d t h : " + H o m e W i d t h + " p x ; h e i g h t : 1 5 p x ; b a c k g r o u n d - c o l o r : " + r o f f + " ; v i s i b i l i t y : v i s i b l e ; c u r s o r : h a n d ; \ "   o n m o u s e o v e r = \ " s h o w d e p s ( l a s t , f a l s e ) ; m r o l l ( ' m t o p . ' ) ; \ "   o n m o u s e o u t = \ " u n m r o l l ( ' m t o p . ' ) ; \ " > < d i v   c l a s s = ' m e n u I E b ' > < a   h r e f = ' " + H o m e L i n k + " '   c l a s s = ' m e n u I E b '   o n f o c u s = ' t h i s . b l u r ( ) ; ' > & n b s p ; " + H o m e T e x t + " < / a > < / d i v > < / d i v > " ) ;  
 	 f o r   ( i = 0 ; i < v o c i . l e n g t h ; i + + )  
 	 	 {  
 	 	 v a r   n = i ;  
 	 	 d o c u m e n t . w r i t e l n ( " < d i v   i d = ' m t o p " + n + " . '   s t y l e = \ " p o s i t i o n : a b s o l u t e ; l e f t : " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + " p x ; t o p : " + t o p m a r g i n + " p x ; w i d t h : " + l a r g o + " p x ; h e i g h t : 1 5 p x ; b a c k g r o u n d - c o l o r : " + r o f f + " ; v i s i b i l i t y : v i s i b l e ; c u r s o r : h a n d \ "   o n m o u s e o v e r = \ " M o s t r a M e n u ( " + n + " ) ; m r o l l ( ' m t o p " + n + " . ' ) ; c o n t a + + ; \ "   o n m o u s e o u t = \ " l a s t = " + n + " ; u n m r o l l ( ' m t o p " + n + " . ' ) ; c o n t a - - ; \ " > < d i v   s t y l e = ' t e x t - a l i g n   :   c e n t e r   ;   '   c l a s s = ' m e n u I E b '   o n c l i c k = \ " v a i ( ' " + l i n k s [ i ] [ 0 ] + " ' , " + i + " , 0 ) ; \ " > & n b s p ; " + v o c i [ i ] [ 0 ] + " < / d i v > < / d i v > " ) ;  
 	 	 f o r   ( l = 1 ; l < v o c i [ i ] . l e n g t h ; l + + )  
 / / 	 	 	 d o c u m e n t . w r i t e l n ( " < d i v   i d = ' m d e p " + i + " . " + l + " '   s t y l e = \ " p o s i t i o n : a b s o l u t e ; l e f t : " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + " p x ; t o p : " + e v a l ( t o p m a r g i n + 1 5 * l ) + " p x ; w i d t h : " + l a r g o + " p x ; h e i g h t : 1 5 p x ; b a c k g r o u n d - c o l o r : " + r o f f + " ; v i s i b i l i t y : h i d d e n ; c u r s o r : h a n d \ "   o n m o u s e o v e r = \ " m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a + + ; \ "   o n m o u s e o u t = \ " u n m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a - - ; \ "   c l a s s = ' m e n u I E '   o n c l i c k = \ " v a i ( ' " + l i n k s [ i ] [ l ] + " ' , " + i + " , " + l + " ) ; \ " > & n b s p ; " + v o c i [ i ] [ l ] + " < / d i v > " ) ;  
 	 	 	 d o c u m e n t . w r i t e l n ( " < d i v   i d = ' m d e p " + i + " . " + l + " '   s t y l e = \ " p o s i t i o n : a b s o l u t e ; l e f t : " + e v a l ( l e f t m a r g i n + H o m e W i d t h + l a r g o * i ) + " p x ; t o p : " + e v a l ( t o p m a r g i n + 1 5 * l ) + " p x ; w i d t h : 1 7 0 p x ; h e i g h t : 1 5 p x ; b a c k g r o u n d - c o l o r : " + r o f f + " ; v i s i b i l i t y : h i d d e n ; c u r s o r : h a n d \ "   o n m o u s e o v e r = \ " m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a + + ; \ "   o n m o u s e o u t = \ " u n m r o l l ( ' m d e p " + n + " . " + l + " ' ) ; c o n t a - - ; \ "   c l a s s = ' m e n u I E '   o n c l i c k = \ " v a i ( ' " + l i n k s [ i ] [ l ] + " ' , " + i + " , " + l + " ) ; \ " > & n b s p ; " + v o c i [ i ] [ l ] + " < / d i v > " ) ;  
 	 	 }  
 	 }  
  
 t i m e r = s e t I n t e r v a l ( " N a s c o n d i M e n u ( ) " , 1 0 0 0 )  
  
 f u n c t i o n   N a s c o n d i M e n u ( )  
 	 {  
 	 i f   ( c o n t a = = 0 )  
 	 	 {  
 	 	 c o l o r a t u t t i ( t r u e )  
 	 	 t i m e r = s e t T i m e o u t ( " c o l o r a t u t t i ( f a l s e ) " , 2 0 0 ) ;  
 	 	 t i m e r = s e t T i m e o u t ( " s h o w d e p s ( l a s t , f a l s e ) " , 2 5 0 ) ;  
 	 	 }  
 	 }  
  
 f u n c t i o n   c o l o r a t u t t i ( c o l )  
 	 {  
 	 c o l o r e = c o l ? r o n : r o f f ;  
 	 f o r   ( i = 0 ; i < v o c i . l e n g t h ; i + + )  
 	 	 f o r   ( j = 1 ; j < v o c i [ i ] . l e n g t h ; j + + )  
 	 	 	 {  
 	 	 i f   ( n n )  
 	 	 	 d o c u m e n t . l a y e r s [ " m d e p " + i + " . " + j ] . b g C o l o r = c o l o r e ;  
 	 	 e l s e  
 	 	 	 i f ( d o c u m e n t . a l l )  
 	 	 	 	 d o c u m e n t . a l l [ " m d e p " + i + " . " + j ] . s t y l e . b a c k g r o u n d = c o l o r e ;  
 	 	 	 	 e l s e  
 	 	 	 	 d o c u m e n t . g e t E l e m e n t B y I d ( ' m d e p ' + i + " . " + j ) . s t y l e . b a c k g r o u n d = c o l o r e ;  
 	 	 	 }  
 	 }  
  
 f u n c t i o n   M o s t r a M e n u ( n )  
 	 {  
 	 s h o w d e p s ( l a s t , f a l s e ) ;  
 	 s h o w d e p s ( n , t r u e ) ;  
 	 l a s t = n ;  
 	 }  
  
 f u n c t i o n   s h o w d e p s ( n , a c t )  
 	 {  
 	 i f   ( c o n t a = = 0 )  
 	 	 {  
 	 	 a c t ? s t a t = " v i s i b l e " : s t a t = " h i d d e n " ;  
 	 i f   ( n n )  
 	 	 f o r   ( i = 1 ; i < v o c i [ n ] . l e n g t h ; i + + )  
 	 	 	 d o c u m e n t . l a y e r s [ " m d e p " + n + " . " + i ] . v i s i b i l i t y = s t a t ;  
 	 e l s e  
 	 	 f o r   ( i = 1 ; i < v o c i [ n ] . l e n g t h ; i + + )  
 	 	 	 i f ( d o c u m e n t . a l l )  
 	 	 	 	 d o c u m e n t . a l l [ " m d e p " + n + " . " + i ] . s t y l e . v i s i b i l i t y = s t a t ;  
 	 	 	 	 e l s e  
 	 	 	 	 d o c u m e n t . g e t E l e m e n t B y I d ( ' m d e p ' + n + " . " + i ) . s t y l e . v i s i b i l i t y = s t a t ;  
 	 	 }  
 	 }  
  
 f u n c t i o n   v a i ( d o v e , r , c )  
 	 {  
 	 i f   ( c > 0 )  
 	 	 l e v = n n ? d o c u m e n t . l a y e r s [ " m d e p " + r + " . " + c ] : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ " m d e p " + r + " . " + c ] . s t y l e : d o c u m e n t . g e t E l e m e n t B y I d ( " m d e p " + r + " . " + c ) . s t y l e ;  
 	 e l s e  
 	 	 l e v = n n ? d o c u m e n t . l a y e r s [ " m t o p " + r + " . " ] : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ " m t o p " + r + " . " ] . s t y l e : d o c u m e n t . g e t E l e m e n t B y I d ( " m t o p " + r + " . " ) . s t y l e ;  
 	 i f   ( n n )  
 	 	 {  
 	 	 l e v . b g C o l o r = r o f f ;  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b g C o l o r = r o n " , 5 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b g C o l o r = r o f f " , 1 0 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b g C o l o r = r o n " , 1 5 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b g C o l o r = r o f f " , 2 0 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b g C o l o r = r o n " , 2 5 0 )  
 	 	 }  
 	 	 e l s e  
 	 	 {  
 	 	 l e v . b a c k g r o u n d = r o f f ;  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b a c k g r o u n d = r o n " , 5 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b a c k g r o u n d = r o f f " , 1 0 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b a c k g r o u n d = r o n " , 1 5 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b a c k g r o u n d = r o f f " , 2 0 0 )  
 	 	 t i m e r = s e t T i m e o u t ( " l e v . b a c k g r o u n d = r o n " , 2 5 0 )  
 	 	 }  
       	 i f   ( n a v i g a t o r . u s e r A g e n t . t o L o w e r C a s e ( ) . i n d e x O f ( " m s i e " ) ! = - 1   & &   n a v i g a t o r . p l a t f o r m . t o L o w e r C a s e ( ) . i n d e x O f ( " m a c " ) = = " m a c " )  
 	       d o c u m e n t . w r i t e ( " " )      
 	  
 	 d e s t = t a r g e t s [ r ] [ c ] . s p l i t ( " | " ) ;  
 	 s w i t c h   ( d e s t [ 0 ] )  
 	 	 {  
 	 	 c a s e   " t o p "   :   t i m e r = s e t T i m e o u t ( " t o p . l o c a t i o n . h r e f = ' " + d o v e + " ' " , 3 5 0 )   ;   b r e a k ;  
 	 	 c a s e   " s e l f "   :   t i m e r = s e t T i m e o u t ( " s e l f . l o c a t i o n . h r e f = ' " + d o v e + " ' " , 3 5 0 )   ;   b r e a k ;  
 	 	 c a s e   " w i n "   :   t i m e r = s e t T i m e o u t ( " w i n d o w . o p e n ( ' " + d o v e + " ' ) " , 3 5 0 )   ;   b r e a k ;  
 	 	 c a s e   " f "   :   t i m e r = s e t T i m e o u t ( " p a r e n t . " + d e s t [ 1 ] + " . l o c a t i o n . h r e f = ' " + d o v e + " ' " , 3 5 0 )   ;   b r e a k ;  
 	 	 c a s e   " p "   :   t i m e r = s e t T i m e o u t ( " w i n d o w . o p e n ( ' " + d o v e + " ' , ' ' , ' " + d e s t [ 1 ] + " ' ) " , 3 5 0 )   ;   b r e a k ;  
 	 	 d e f a u l t   :   t i m e r = s e t T i m e o u t ( " s e l f . l o c a t i o n . h r e f = ' " + d o v e + " ' " , 3 5 0 ) ;  
 	 	 }  
 	 }  
  
 f u n c t i o n   m r o l l ( l )  
 	 {  
 	 L T o p = " m t o p " + l . s u b s t r ( 4 , l . i n d e x O f ( " . " ) - 4 ) + " . " ;  
 	 n n ? d o c u m e n t . l a y e r s [ L T o p ] . b g C o l o r = r o n : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ L T o p ] . s t y l e . b a c k g r o u n d = r o n : d o c u m e n t . g e t E l e m e n t B y I d ( L T o p ) . s t y l e . b a c k g r o u n d = r o n ;  
 	 n n ? d o c u m e n t . l a y e r s [ l ] . b g C o l o r = r o n : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ l ] . s t y l e . b a c k g r o u n d = r o n : d o c u m e n t . g e t E l e m e n t B y I d ( l ) . s t y l e . b a c k g r o u n d = r o n ;  
 	 d o c u m e n t . g e t E l e m e n t B y 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 ) . s t y l e . c u r s o r = d o c u m e n t . a l l ? ' h a n d ' : ' p o i n t e r ' : ' v o i d ( 0 ) ' ;  
 	 i f   ( l . s u b s t r ( 0 , 4 ) = = " m d e p " )  
 	 	 s t r i n g a = w s t [ l . s u b s t r ( 4 , l . i n d e x O f ( " . " ) - 4 ) ] [ l . s u b s t r i n g ( l . i n d e x O f ( " . " ) + 1 , l . l e n g t h ) ] ;  
 	 	 	 e l s e   i f   ( l . l e n g t h > 5 )  
 	 	 	 s t r i n g a = w s t [ l . s u b s t r ( 4 , l . i n d e x O f ( " . " ) - 4 ) ] [ 0 ] ;  
 	 	 	 	 e l s e   s t r i n g a = " H o m e   P a g e " ; 	 	  
 	 w i n d o w . s t a t u s = s t r i n g a ;  
 	 t i m e r = s e t T i m e o u t ( " w i n d o w . s t a t u s = s t r i n g a " , 2 0 ) ;  
 	 }  
  
 f u n c t i o n   u n m r o l l ( l )  
 	 {  
 	 L T o p = " m t o p " + l . s u b s t r ( 4 , l . i n d e x O f ( " . " ) - 4 ) + " . " ;  
 	 n n ? d o c u m e n t . l a y e r s [ L T o p ] . b g C o l o r = r o f f : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ L T o p ] . s t y l e . b a c k g r o u n d = r o f f : d o c u m e n t . g e t E l e m e n t B y I d ( L T o p ) . s t y l e . b a c k g r o u n d = r o f f ;  
 	 n n ? d o c u m e n t . l a y e r s [ l ] . b g C o l o r = r o f f : ( d o c u m e n t . a l l ) ? d o c u m e n t . a l l [ l ] . s t y l e . b a c k g r o u n d = r o f f : d o c u m e n t . g e t E l e m e n t B y I d ( l ) . s t y l e . b a c k g r o u n d = r o f f ;  
 	 w i n d o w . s t a t u s = " " ;  
 	 }  
  
 o n r e s i z e = f u n c t i o n ( )   { s e l f . l o c a t i o n . r e l o a d ( ) } ;  
 
