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