ÿþf u n c t i o n   p a r s e F n ( d a t a )  
 {  
         v a r   r o w s   =   [ ] ;  
         f o r ( v a r   i = 0 ;   i < d a t a . l e n g t h ;   i + + ) {  
             r o w s [ r o w s . l e n g t h ]   =  
             {  
                   d a t a : d a t a [ i ] ,  
                   v a l u e : d a t a [ i ] . q ,  
                   r e s u l t : d a t a [ i ] . q  
             } ;  
         }  
         r e t u r n   r o w s ;  
 }  
 f u n c t i o n   f i n d V a l u e C a l l b a c k ( e v e n t ,   d a t a ,   f o r m a t t e d )    
 {  
       / / a l e r t ( d a t a . i d ) ;  
 }  
 $ ( f u n c t i o n ( )   {  
 $ ( " # a u t o k e y w o r d " ) . a u t o c o m p l e t e ( " / a u t o . a s h x " , {  
           m i n C h a r s :   1 ,    
           w i d t h :   1 7 0 ,  
           s c r o l l H e i g h t :   3 0 0 ,  
           d a t a T y p e : ' j s o n ' ,  
           s e l e c t F i r s t : f a l s e ,    
           m a x :   1 0 ,  
           p a r s e : p a r s e F n ,  
           f o r m a t I t e m :   f u n c t i o n ( r o w ,   i ,   m a x )    
           {  
                 v a r   i t e m = " < d i v   s t y l e = ' w i d t h : 1 6 8 x ; ' > < d i v   s t y l e = ' f l o a t : l e f t ; w i d t h : 1 2 0 p x ; ' > " +   r o w . q   + " < / d i v > < d i v   a l i g n = ' r i g h t '   s t y l e = \ " c o l o r : g r e e n ; w i d t h : 4 5 p x ; f l o a t : r i g h t \ " > d" + r o w . n u m + " !k< / d i v > < / d i v > " ;  
                 r e t u r n   i t e m ;  
           }  
         } ) ;  
 $ ( " # a u t o k e y w o r d " ) . r e s u l t ( f i n d V a l u e C a l l b a c k ) ;  
 } ) ;  
 v a r   a j a x = ' ' ;  
 f u n c t i o n   b u y ( p a r a m e t e r )  
 {  
         i f   ( w i n d o w . A c t i v e X O b j e c t )  
         {  
                 a j a x   =   n e w   A c t i v e X O b j e c t ( " M i c r o s o f t . X M L H T T P " ) ;  
         }  
         e l s e   i f   ( w i n d o w . X M L H t t p R e q u e s t )  
         {  
                 a j a x   =   n e w   X M L H t t p R e q u e s t ( ) ;  
         }  
         e l s e  
         {  
                 r e t u r n   f a l s e ;  
         }  
         a j a x . o p e n ( " P O S T " ,   " / b u y . a s h x " ,   t r u e ) ;  
         a j a x . s e t R e q u e s t H e a d e r ( " C o n t e n t - T y p e " ,   " a p p l i c a t i o n / x - w w w - f o r m - u r l e n c o d e d " ) ;  
         a j a x . s e n d ( " o p = b u y & i d = " + p a r a m e t e r ) ;  
         a j a x . o n r e a d y s t a t e c h a n g e   =   A d d B u y O K ;  
 }  
 f u n c t i o n   A d d B u y O K ( )  
 {  
         i f   (   a j a x . r e a d y S t a t e   = =   4   )  
 	 {  
 	 	 i f   (   a j a x . s t a t u s   = =   2 0 0   )  
 	 	 {    
 	 	         v a r   t b o =   a j a x . r e s p o n s e T e x t ;  
                         i f   ( t b o = = ' ' )  
                         {  
                                 r e t u r n   f a l s e ;      
                         }  
                         e l s e  
                         {  
                                 v a r   a r r = t b o . s p l i t ( ' $ A r r y $ ' ) ;  
                                 i f   ( a r r [ 0 ] = = ' O K ' )  
                                 {  
                                         d o c u m e n t . g e t E l e m e n t B y I d ( a r r [ 1 ] ) . i n n e r H T M L = a r r [ 2 ] ;  
                                         d o c u m e n t . g e t E l e m e n t B y I d ( ' r i g h t _ c a r t ' ) . i n n e r H T M L = a r r [ 3 ] ;  
                                 }  
                                 e l s e  
                                 {  
                                         a l e r t ( a r r [ 1 ] ) ;  
                                 }  
                         } 	  
 	 	 }  
 	 	 e l s e  
 	 	 {  
 	 	 	 a l e r t ( " `O@bËŠBl„vkub—|vupu8^ÿïSý€q_ÿ—`Op½‰áOo`ÿ"   +   a j a x . s t a t u s ) ;    
 	 	 }  
         }          
 }  
 f u n c t i o n   s h o w p i c ( p i d )  
 {  
         i f   (   d o c u m e n t . g e t E l e m e n t B y I d ( " p _ " + p i d )   )  
         {  
                 d o c u m e n t . g e t E l e m e n t B y I d ( " p _ " + p i d ) . i n n e r H T M L = ' < i m g   s r c = " / i m a g e s / c a r e d . g i f "   b o r d e r = " 0 "   s t y l e = " c u r s o r : p o i n t e r "   t i t l e = " ò]>eeQüŒirÊŽ" / > ' ;  
         }  
 }  
 f u n c t i o n   g e t S e l e c t T e x t ( )    
 {  
         v a r   d e s c   =   ' ' ;  
         i f ( w i n d o w . g e t S e l e c t i o n )  
                 d e s c = w i n d o w . g e t S e l e c t i o n ( ) ;  
         e l s e   i f ( d o c u m e n t . g e t S e l e c t i o n )  
                 d e s c = d o c u m e n t . g e t S e l e c t i o n ( ) ;  
         e l s e   i f ( d o c u m e n t . s e l e c t i o n )  
                 d e s c = d o c u m e n t . s e l e c t i o n . c r e a t e R a n g e ( ) . t e x t ;  
         e l s e   d e s c   =   ' ' ;  
         r e t u r n   d e s c ;  
 }  
 f u n c t i o n   a d d B o o k m a r k ( s T y p e )    
 {  
         v a r   v i a   = ' ' ;  
         v a r   r e s u l t   =   ' ' ;  
         v a r   s T i t l e   =   e n c o d e U R I C o m p o n e n t ( d o c u m e n t . t i t l e ) ;  
         v a r   s U R L   =   e n c o d e U R I C o m p o n e n t ( l o c a t i o n . h r e f ) ;  
         s D e s c   =   e n c o d e U R I C o m p o n e n t (   g e t S e l e c t T e x t ( ) ) ;  
         i f (   s T y p e = = ( " m y s h a r e " ) )   { r e s u l t   =   ' h t t p : / / m y s h a r e . u r l . c o m . t w / i n d e x . p h p ? f u n c = n e w u r l & u r l = ' + s U R L + ' & d e s c = ' + s T i t l e + ' & c o n t e n t s = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " h e m i d e m i " ) )   { r e s u l t   =   ' h t t p : / / w w w . h e m i d e m i . c o m / u s e r _ b o o k m a r k / n e w ? t i t l e = ' + s T i t l e + ' & u r l = ' + s U R L + ' & d e s c r i p t i o n = ' + s D e s c + ' & v i a = ' + v i a ; }  
         e l s e   i f (   s T y p e = = ( " g o o g l e " ) )   { r e s u l t   =   ' h t t p : / / w w w . g o o g l e . c o m / b o o k m a r k s / m a r k ? o p = a d d & b k m k = ' + s U R L + ' & t i t l e = ' + s T i t l e + ' & a n n o t a t i o n = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " y a h o o " ) )   { r e s u l t   =   ' h t t p : / / t w . m y w e b 2 . s e a r c h . y a h o o . c o m / m y r e s u l t s / b o o k m a r k l e t ? t = ' + s T i t l e + ' & u = ' + s U R L + ' & d = ' + s D e s c + ' & e i = U T F - 8 ' ; }  
         e l s e   i f (   s T y p e = = ( " p c h o m e " ) )   { r e s u l t   =   ' h t t p : / / s e a r c h 2 0 . p o r t a l 2 0 . c o m . t w / x . j s p ? t = ' + s T i t l e + ' & u = ' + s U R L + ' & n = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " u d n " ) )   { r e s u l t   =   ' h t t p : / / b o o k m a r k . u d n . c o m / a d d ? f _ T I T L E = ' + s T i t l e + ' & f _ U R L = ' + s U R L + ' & f _ D I G E S T = ' + s D e s c + ' & v i a = ' + v i a ; }  
         e l s e   i f (   s T y p e = = ( " f i i g o " ) )   { r e s u l t   =   ' h t t p : / / w w w . f i i g o . c o m / b o o k m a r k / m y . p h p ? a = a d d _ w e b & t i t l e = ' + s T i t l e + ' & u r l = ' + s U R L + ' & c o m m e n t = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " y o u p u s h " ) )   { r e s u l t   =   ' h t t p : / / w w w . y o u p u s h . n e t / s u b m i t . p h p ? u r l = ' + s U R L ; }  
         e l s e   i f (   s T y p e = = ( " t e c h n o r a t i " ) )   { r e s u l t   =   ' h t t p : / / t e c h n o r a t i . c o m / f a v e s ? a d d = ' + s U R L + ' & t i t l e = ' + s T i t l e ; }  
         e l s e   i f (   s T y p e = = ( " b a i d u " ) )   { r e s u l t   =   ' h t t p : / / c a n g . b a i d u . c o m / d o / a d d ? i u = ' + s U R L + ' & i t = ' + s T i t l e + ' & d c = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " d e l i c i o u s " ) )   { r e s u l t   =   ' h t t p : / / d e l . i c i o . u s / p o s t ? t i t l e = ' + s T i t l e + ' & u r l = ' + s U R L + ' & n o t e s = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " d i g g " ) )   { r e s u l t   =   ' h t t p : / / d i g g . c o m / s u b m i t ? p h a s e = 2 & u r l = ' + s U R L + ' & t i t l e = ' + s T i t l e + ' & b o d y t e x t = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " f u r l " ) )   { r e s u l t   =   ' h t t p : / / w w w . f u r l . n e t / s t o r e I t . j s p ? t = ' + s T i t l e + ' & u = ' + s U R L + ' & r = ' + e s c a p e ( v i a ) + ' & c = ' + e n c o d e U R I ( s D e s c ) + ' & p = 1 ' ; }  
         e l s e   i f (   s T y p e = = ( " l i v e " ) )   { r e s u l t   =   ' h t t p s : / / f a v o r i t e s . l i v e . c o m / q u i c k a d d . a s p x ? m k t = z h - t w & u r l = ' + s U R L + ' & t i t l e = ' + s T i t l e + ' & t o p = 1 & w a = w s i g n i n 1 . 0 ' ; }  
         e l s e   i f (   s T y p e = = ( " a d d t h i s " ) )   { r e s u l t   =   ' h t t p : / / w w w . a d d t h i s . c o m / b o o k m a r k . p h p ? p u b = a d d t h i s & u r l = ' + s U R L + ' & t i t l e = ' + s T i t l e ; }  
         e l s e   i f (   s T y p e = = ( " f u n p " ) )   { r e s u l t   =   ' h t t p : / / f u n p . c o m / p a g e s / s u b m i t / a d d . p h p ? & t a g s [ ] = % E 6 % 9 6 % B 0 % E 8 % 8 1 % 9 E & t a g s [ ] = % E 7 % 9 4 % 9 F % E 6 % B 4 % B B & t a g s [ ] = % E 9 % 8 6 % A B % E 5 % A D % B 8 & t a g s [ ] = % E 7 % B E % 8 E % E 5 % A E % B 9 & t a g s [ ] = % E 5 % 8 1 % A 5 % E 5 % B A % B 7 & t a g s [ ] = u h o & v i a = t o o l s & & s = ' + s T i t l e + ' & u r l = ' + s U R L + ' & r = ' + e s c a p e ( v i a ) + ' & t = ' + s D e s c ; }  
         e l s e   i f (   s T y p e = = ( " p l u r k " ) )   { r e s u l t   =   ' h t t p : / / p l u r k . c o m / ? s t a t u s = '   +   s U R L   +   '   '   +   ' ( '   +   ( ( d o c u m e n t . t i t l e )   ?   e n c o d e U R I C o m p o n e n t ( d o c u m e n t . t i t l e . r e p l a c e ( / ^ \ s * | \ s * $ / g , ' ' ) )   :   ' ' )   +   ' ) ' ; }  
         e l s e   i f (   s T y p e = = ( " f a c e b o o k " ) )   { r e s u l t   =   ' h t t p : / / w w w . f a c e b o o k . c o m / s h a r e . p h p ? u = ' + s U R L + ' & t i t l e = ' + s T i t l e ; }  
         e l s e   i f (   s T y p e = = ( " t w i t t e r " ) )   { r e s u l t   =   ' h t t p : / / t w i t t e r . c o m / h o m e / ? s t a t u s = ' + s U R L + ' & t i t l e = ' + s T i t l e ; }  
         e l s e   i f (   s T y p e = = ( " m u r m u r " ) )   { r e s u l t   =   ' h t t p : / / m u r m u r . t w / ? s h a r e l i n k = ' + s U R L ; }  
  
         i f ( r e s u l t ! = ' ' )   { w i n d o w . o p e n (   r e s u l t ,   ' a d d b o o k m a k ' ) ; }  
 }  
 f u n c t i o n   d o w n l o a d t x t ( o i d )    
 {  
         w i n d o w . o p e n ( ' / d o w n l o a d . a s p x ? o i d = '   +   o i d , ' d o w n l o a d t x t ' , ' s c r o l l b a r s = y e s , t o p = ' + ( s c r e e n . h e i g h t - 5 0 ) / 2 + ' , l e f t = ' + ( s c r e e n . w i d t h - 1 0 0 ) / 2 + ' , w i d t h = 1 0 0 , h e i g h t = 5 0 , r e s i z a b l e = y e s ' ) ;  
 }  
 f u n c t i o n   s e t _ h e i g h t ( )  
 {  
         v a r   a = d o c u m e n t . g e t E l e m e n t B y I d ( " b i g _ l e f t " )  
         v a r   b = d o c u m e n t . g e t E l e m e n t B y I d ( " b i g _ r i g h t " )  
         v a r   c = d o c u m e n t . g e t E l e m e n t B y I d ( " b i g _ r i g h t _ c a r t " )  
         v a r   d  
         i f   ( a . s c r o l l H e i g h t < b . s c r o l l H e i g h t )            
         {  
                 d = b . s c r o l l H e i g h t ;  
         }  
         e l s e  
         {  
                 d = a . s c r o l l H e i g h t ;  
         }  
         i f   ( d < c . s c r o l l H e i g h t )  
         {  
                 d = c . s c r o l l H e i g h t ;  
         }  
         e l s e  
         {  
                 d = d ;  
         }  
         a . s t y l e . h e i g h t = d + " p x " ;  
         b . s t y l e . h e i g h t = d + " p x " ;  
         c . s t y l e . h e i g h t = d + " p x " ;  
 } 
