ÿþf u n c t i o n   a d d T o C a r 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 ( ' c t l 0 0 _ h i d A d d T o C a r t ' ) . v a l u e   =   i d ;  
     d o c u m e n t . f o r m s [ 0 ] . s u b m i t ( ) ;  
 }  
 f u n c t i o n   s h o w Z o o m ( s o u r c e ,   h e i g h t ,   w i d t h )   {  
     v a r   s U r l ;  
     v a r   s N a m e = ' a t g _ 6 a 1 i 2 _ z o o m ' ;  
     v a r   s H e i g h t ;  
     v a r   s W i d t h ;  
     v a r   s F e a t u r e s ;  
     v a r   o W i n ;  
      
     s H e i g h t   =   ' 4 0 0 ' ;  
     i f   ( h e i g h t )   {  
         s H e i g h t   =   p a r s e I n t ( h e i g h t )   +   1 0 0 ;  
     }  
     s W i d t h   =   ' 3 5 0 ' ;  
     i f   ( w i d t h )   {  
         s W i d t h   =   p a r s e I n t ( w i d t h )   +   5 0 ;  
     }  
     s F e a t u r e s = ' r e s i z a b l e = y e s , h e i g h t = '   +   s H e i g h t   +   ' , w i d t h = '   +   s W i d t h   +   ' , s c r o l l b a r s = n o , s t a t u s = y e s , t o o l b a r = n o ' ;  
      
     s U r l   =   s o u r c e ;  
      
     t r y   {  
         o W i n   =   w i n d o w . o p e n ( s U r l ,   s N a m e ,   s F e a t u r e s ,   t r u e ) ;  
          
         / / F i x   s a f a r i   w i n d o w   i f   i t   d i d n ' t   s i z e   p r o p e r l y  
         i f   ( o W i n . i n n e r W i d t h )   {  
             i f   ( p a r s e I n t ( o W i n . i n n e r W i d t h )   <   p a r s e I n t ( s W i d t h ) )   {  
                 o W i n . r e s i z e T o ( s W i d t h ,   s H e i g h t ) ;  
             }  
         }  
         o W i n . f o c u s ( ) ;  
     }   c a t c h ( e )   {  
         i f   ( ! o W i n )   {  
             a l e r t ( ' T o   v i e w   a   z o o m   o f   t h e   i m a g e ,   p l e a s e   t u r n   o f f   y o u r   p o p u p   b l o c k e r . ' ) ;  
         }      
     }   / / c a t c h  
 }  
  
 
