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