ÿþf u n c t i o n   p u t i m a g e ( s t r i m g ,   i m g M a i n I m a g e ,     s t r v i s i m g ,   i m g v i s )  
 {  
       / / a l e r t ( ' '   +   s t r i m g   +   ' ' ) ;  
         i m g M a i n I m a g e . s r c   =   s t r i m g ;  
         i m g v i s . v a l u e   =   s t r v i s i m g ;  
         r e t u r n   f a l s e ;  
 }  
  
 f u n c t i o n   g e t f i n g e r ( f i n g e r ,   p r d f i n g e r )  
 {  
         p r d f i n g e r . v a l u e   =   f i n g e r . v a l u e ;  
        
 }  
  
 f u n c t i o n   c l e a r t e x t ( t e x t o b j e c t )   {  
         i f   ( t e x t o b j e c t . v a l u e   = =   " ÓÕÐ' ' Ü"   | |   t e x t o b j e c t . v a l u e   = =   " éÝ"   | |   t e x t o b j e c t . v a l u e   = =   " Þáäè  ØÜäÕß"   | |   t e x t o b j e c t . v a l u e   = =   " N a m e "   | |   t e x t o b j e c t . v a l u e   = =   " P h o n e   N o "   | |   t e x t o b j e c t . v a l u e   = =   " E m a i l "   | |   t e x t o b j e c t . v a l u e   = =   " C i t y " )  
         {  
                 t e x t o b j e c t . v a l u e   =   " " ;  
         }  
 }  
  
  
 / / c h e c k c o n t a c t u s  
 f u n c t i o n   c h e c k c o n t a c t u s ( p h o n e , a r r M s g )  
 {  
  
         i f   ( e m p t y F i e l d ( p h o n e ) )   {  
                 a l e r t ( a r r M s g [ 0 ] ) ;  
                 p h o n e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
         e l s e  
         {  
                 i f   ( p h o n e . v a l u e   = =   " Þáäè  ØÜäÕß"   | |   p h o n e . v a l u e   = =   " P h o n e   N o " )  
                 {  
                         / / a l e r t ( ' Þáäè  ØÜäÕß' ) ;  
                           a l e r t ( a r r M s g [ 0 ] ) ;  
                         p h o n e . f o c u s ( ) ;  
                         r e t u r n   f a l s e ;  
                 }  
         }  
  
 }  
  
  
  
 f u n c t i o n   c h e c k _ q t y ( t x t q t y )  
 {                        
 	 	 	 	 v a r   t e s t   = 0 ;  
 	 	 	 	 v a r   c o n   =   2 ;  
 	 	 	 	 v a r   c o n 2   =   2 ;  
 	 	 	 	 f o r   ( v a r   i = 0 ;   i < d o c u m e n t . F o r m 1 . l e n g t h ;   i + + )  
 	 	 	 	 {  
 	 	 	 	  
 	 	 	 	 	   i f   ( d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) )  
 	 	 	 	 	   {  
 	 	 	 	 	         i f   ( e m p t y F i e l d ( d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) ) )  
 	 	 	 	 	 	 	 	 {  
 	 	 	 	 	 	 	 	 	 a l e r t ( ' P l e a s e   E n t e r   Q u a n t i t y ' ) ;  
 	 	 	 	 	 	 	 	 	 d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	 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 ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) . v a l u e   <   1 )  
 	 	 	 	 	 	 	 	  
 	 	 	 	 	 	 	 	 {  
 	 	 	 	 	 	 	 	 	 a l e r t ( ' Q u a n t i t y   M u s t   B e   G r e a t e r   T h e n   Z e r o . ' ) ;  
 	 	 	 	 	 	 	 	 	 d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	 r e t u r n   f a l s e ;  
 	 	 	 	 	 	 	 	 }  
 	 	 	 	 	  
 	 	 	 	 	 	 	 i f   ( ! i s 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 ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) . v a l u e ) )  
 	 	 	 	 	 	 	 	  
 	 	 	 	 	 	 	 	 {  
 	 	 	 	 	 	 	 	 	 a l e r t ( ' P l e a s e   E n t e r   I n t e g e r   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 ( " D a t a G r i d 1 _ _ c t l " + c o n + " _ t x t q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	 r e t u r n   f a l s e ;  
 	 	 	 	 	 	 	 	 }  
 	 	 	 	 	  
 	 	 	 	 	  
 	 	 	 	 	 	 c o n   = c o n   +   1 ; 	  
 	 	 	 	 	    
 	 	 	 	 	   }  
 	 	 	 	 	 	 	  
 	 	 	 	 	 	 / / / a d d e d   n e w   f o r   g i f t   v o u c h 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 ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) )  
 	 	 	                               {  
 	 	 	                                 i f   ( e m p t y F i e l d ( d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) ) )  
 	 	 	 	 	 	 	 	                 {  
 	 	 	 	 	 	 	 	 	                 a l e r t ( ' P l e a s e   E n t e r   Q u a n t i t y ' ) ;  
 	 	 	 	 	 	 	 	 	                 d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	                 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 ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) . v a l u e   <   1 )  
                 	 	 	 	 	 	 	 	  
 	 	 	 	 	 	 	 	                 {  
 	 	 	 	 	 	 	 	 	                 a l e r t ( ' Q u a n t i t y   M u s t   B e   G r e a t e r   T h e n   Z e r o . ' ) ;  
 	 	 	 	 	 	 	 	 	                 d o c u m e n t . g e t E l e m e n t B y I d ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	                 r e t u r n   f a l s e ;  
 	 	 	 	 	 	 	 	                 }  
                 	 	 	 	 	  
 	 	 	 	 	 	 	                 i f   ( ! i s 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 ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) . v a l u e ) )  
                 	 	 	 	 	 	 	 	  
 	 	 	 	 	 	 	 	                 {  
 	 	 	 	 	 	 	 	 	                 a l e r t ( ' P l e a s e   E n t e r   I n t e g e r   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 ( " D a t a G r i d 2 _ _ c t l " + c o n 2 + " _ t x t g v q t y " ) . f o c u s ( ) ;  
 	 	 	 	 	 	 	 	 	                 r e t u r n   f a l s e ;  
 	 	 	 	 	 	 	 	                 }                 	 	 	                
 	 	 	                               } 	 	  
 	 	 	 	                 c o n 2   = c o n 2   +   1 ; 	  
 	 	 	 	 	 	 / / / e n d   a d d e d   n e w   f o r   g i f t   v o u c h e r / / / /  
 	 	 	 	 	 	 	  
 	 	 	 	 }  
 	 	  
 	 	 	 	  
 	 	 	 	  
 	 	 	 	  
 }  
  
  
 f u n c t i o n   s e t _ s h i p p i n g I n f o ( c h k S h i p ,   t x t F N a m e ,   t x t L N a m e ,   t x t A d d r e s s 1 ,   t x t A d d r e s s 2 ,   t x t C i t y ,   t x t S t a t e ,   d d l C o u n t r y ,   t x t Z i p ,   t x t P h o n e ,   t x t S F N a m e ,   t x t S L N a m e ,   t x t S A d d r e s s 1 ,   t x t S A d d r e s s 2 ,   t x t S C i t y ,   t x t S S t a t e ,   d d l S C o u n t r y ,   t x t S Z i p ,     t x t S P h o n e )  
 {  
 	 i f ( c h k S h i p . c h e c k e d = = t r u e )  
 	 {  
 	 	 t x t S F N a m e . v a l u e   = t x t F N a m e . v a l u e ;  
 	 	 t x t S L N a m e . v a l u e   =   t x t L N a m e . v a l u e ;  
 	 	 t x t S A d d r e s s 1 . v a l u e   =   t x t A d d r e s s 1 . v a l u e ;  
 	 	 t x t S A d d r e s s 2 . v a l u e   =   t x t A d d r e s s 2 . v a l u e ;  
 	 	 t x t S C i t y . v a l u e   =   t x t C i t y . v a l u e ;  
 	 	 t x t S S t a t e . v a l u e   =   t x t S t a t e . v a l u e ;  
 	 	 d d l S C o u n t r y . v a l u e   =   d d l C o u n t r y . v a l u e ;  
 	 	 t x t S Z i p . v a l u e   =   t x t Z i p . v a l u e ; 	  
 	         t x t S P h o n e . v a l u e   =   t x t P h o n e . v a l u e ;  
 	 	 	  
 	 }  
 	 e l s e   i f   ( c h k S h i p . c h e c k e d   = =   f a l s e )  
 	 {  
 	 	 t x t S F N a m e . v a l u e   =   " " ;  
 	 	 t x t S L N a m e . v a l u e   =   " " ;  
 	 	 t x t S A d d r e s s 1 . v a l u e   =   " " ;  
 	 	 t x t S A d d r e s s 2 . v a l u e   =   " " ;  
 	 	 t x t S C i t y . v a l u e   =   " " ;  
 	 	 t x t S S t a t e . v a l u e   =   " " ;  
 	 	 t x t S Z i p . v a l u e   =   " " ;  
 	 	 d d l S C o u n t r y . v a l u e   =   d d l C o u n t r y . v a l u e ;  
 	 	 t x t S P h o n e . v a l u e   =   " " ;  
 	 }  
 }  
 f u n c t i o n   c h e c k _ b i l l i n g I n f o ( t x t F N a m e ,   t x t L N a m e ,   t x t A d d r e s s 1 ,   t x t C i t y ,   t x t S t a t e ,   d d l C o u n t r y ,   t x t Z i p ,   t x t P h o n e ,   t x t S F N a m e ,   t x t S L N a m e ,   t x t S A d d r e s s 1 ,   t x t S C i t y ,   t x t S S t a t e ,   d d l S C o u n t r y ,   t x t S Z i p ,     t x t S P h o n e ,   a r r M s g )  
 {  
 	 v a r   a r g ;  
 	 v a r   f l a g ;  
 	  
 	  
 	 / /   c h e c k   b i l l i n g   i n f o   f i e l d s  
 	 i f   ( e m p t y F i e l d ( t x t F N a m e ) )  
 	 {  
 	 	 a l e r t ( a r r M s g [ 0 ] ) ;  
 	 	 t x t F N a m e . f o c u s ( ) ;  
 	 	 r e t u r n   f a l s e ;  
 	 }  
 	 i f   ( e m p t y F i e l d ( t x t L N a m e ) )  
 	 {  
 	         a l e r t ( a r r M s g [ 1 ] ) ;  
 	 	 t x t L N a m e . f o c u s ( ) ;  
 	 	 r e t u r n   f a l s e ;  
         }  
       i f   ( e m p t y F i e l d ( t x t A d d r e s s 1 ) )   {  
               a l e r t ( a r r M s g [ 2 ] ) ;  
                 t x t A d d r e s s 1 . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
      
         i f   ( e m p t y F i e l d ( t x t C i t y ) )   {  
                 a l e r t ( a r r M s g [ 3 ] ) ;  
                 t x t C i t y . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
  
         i f   ( e m p t y F i e l d ( t x t S t a t e ) )   {  
                 a l e r t ( a r r M s g [ 4 ] ) ;  
                 t x t S t a t e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
  
        
         i f   ( d d l C o u n t r y . v a l u e   = =   " 0 " )   {  
                 a l e r t ( a r r M s g [ 5 ] ) ;  
                 d d l C o u n t r y . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
  
         i f   ( e m p t y F i e l d ( t x t Z i p ) )   {  
                 a l e r t ( a r r M s g [ 6 ] ) ;  
                 t x t Z i p . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
  
         i f   ( e m p t y F i e l d ( t x t P h o n e ) )   {  
                 a l e r t ( a r r M s g [ 7 ] ) ;  
                 t x t P h o n e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
 	  
 	   i f   ( e m p t y F i e l d ( t x t S F N a m e ) )   {  
 	           a l e r t ( a r r M s g [ 8 ] ) ;  
                 t x t S F N a m e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
 	  
 	   i f   ( e m p t y F i e l d ( t x t S L N a m e ) )   {  
 	           a l e r t ( a r r M s g [ 9 ] ) ;  
                 t x t S L N a m e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
 	   i f   ( e m p t y F i e l d ( t x t S A d d r e s s 1 ) )   {  
 	           a l e r t ( a r r M s g [ 1 0 ] ) ;  
                 t x t S A d d r e s s 1 . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
         / /   t x t S A d d r e s s 1 ,   t x t S C i t y ,   t x t S S t a t e ,   d d l S C o u n t r y ,   t x t S Z i p ,     t x t S P h o n e  
 	     i f   ( e m p t y F i e l d ( t x t S C i t y ) )   {  
 	             a l e r t ( a r r M s g [ 1 1 ] ) ;  
                 t x t S C i t y . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
         i f   ( e m p t y F i e l d ( t x t S S t a t e ) )   {  
                 a l e r t ( a r r M s g [ 1 2 ] ) ;  
                 t x t S S t a t e . f o c u s ( ) ;  
                 r e t u r n   f a l s e ;  
         }  
 	  
 	     i f   ( d d l S C o u n t r y . v a l u e   = =   " 0 " )  
 	 {  
 	         a l e r t ( a r r M s g [ 1 3 ] ) ;  
 	 	 d d l S C o u n t r y . f o c u s ( ) ;  
 	 	 r e t u r n   f a l s e ;  
 	 }  
 	 i f   ( e m p t y F i e l d ( t x t S Z i p ) )   {  
 	         a l e r t ( a r r M s g [ 1 4 ] ) ;  
 	         t x t S Z i p . f o c u s ( ) ;  
 	         r e t u r n   f a l s e ;  
 	 }  
 	 i f   ( e m p t y F i e l d ( t x t S P h o n e ) )   {  
 	         a l e r t ( a r r M s g [ 1 5 ] ) ;  
 	         t x t S P h o n e . f o c u s ( ) ;  
 	         r e t u r n   f a l s e ;  
 	 }  
 	  
 	  
 }  
  
  
  
 f u n c t i o n   g e t O b j e c t B y I D ( O b j i d ) { 	  
 	 	 	 	 v a r   n s 4   =   d o c u m e n t . l a y e r s ;  
 	 	 	 v a r   n s 6   =   d o c u m e n t . g e t E l e m e n t B y I d   & &   ! d o c u m e n t . a l l ;  
 	 	 	 v a r   i e 4   =   d o c u m e n t . a l l ;  
 	 	 	 	 i f ( n s 4 )  
 	 	 	 	 {  
 	 	 	 	 	 r e t u r n   e v a l ( ' d o c u m e n t . '   +   O b j i d )  
 	 	 	 	 }  
 	 	 	 	 i f ( n s 6 )  
 	 	 	 	 {  
 	 	 	 	 	 r e t u r n   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 i d ) ;  
 	 	 	 	 }  
 	 	 	 	 i f ( i e 4 )  
 	 	 	 	 {  
 	 	 	 	 	 r e t u r n   d o c u m e n t . a l l ( O b j i d ) ;              
 	 	 	 	 }      
 	 	 	 	 r e t u r n   n u l l  
 	 	 	 }  
  
  
 	 	 	 f u n c t i o n   S e t T e x t ( o b j i d , m s g ,   f g ,   b g ) {  
 	 	 	 	 v a r   n s 4   =   d o c u m e n t . l a y e r s ;  
 	 	 	 v a r   n s 6   =   d o c u m e n t . g e t E l e m e n t B y I d   & &   ! d o c u m e n t . a l l ;  
 	 	 	 v a r   i e 4   =   d o c u m e n t . a l l ;  
 	 	 	 	 i f ( ! f g )   f g   =   " # f f 0 0 0 0 " ;  
 	 	 	 	 i f ( ! b g )   b g   =   " # F F F F F F " ;  
 	 	 	 	  
 	 	 	 	 v a r   c o n t e n t   =   m s g   ;  
 	 	 	 	 i f ( n s 4 )  
 	 	 	 	 {  
 	 	 	 	 	 o b j I t m   =   e v a l ( ' d o c u m e n t . '   +   o b j i d )  
 	 	 	 	 	 o b j I t m . d o c u m e n t . w r i t e ( c o n t e n t ) ;  
 	 	 	 	 	 o b j I t m . d o c u m e n t . c l o s e ( ) ;  
 	 	 	 	 	 o b j I t m . v i s i b i l i t y   =   " v i s i b l e " ;  
 	 	 	 	 }  
 	 	 	 	 i f ( n s 6 )  
 	 	 	 	 {  
 	 	 	 	 	 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 i d ) . i n n e r H T M L   =   c o n t e n t ;  
 	 	 	 	 }  
 	 	 	 	 i f ( i e 4 )  
 	 	 	 	 {  
 	 	 	 	 	 d o c u m e n t . a l l ( o b j i d ) . i n n e r H T M L = c o n t e n t ;  
 	 	 	 	 }      
 	 	 	 }  
 	 	 	  
 	 	 	  
 	 	 / / / v i s h a l   s c r i p t / / 	  
 	 	 / * f u n c t i o n   c h e c k _ r a d i o b u t t o n ( )  
 	 	 {    
 	 	 	 v a r   i ;  
 	 	 	 v a r   t o t ;  
 	 	 	 f o r ( i = 0 ; i < d o c u m e n t . F o r m 1 . l e n g t h ; i + + )  
 	 	 	 {  
 	 	 	 	 i f ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . t y p e = = " r a d i o " )  
 	 	 	 	 {  
 	 	 	 	 	 i f ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . c h e c k e 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 ( " N e t P r c " ) . v a l u e 	   =   p a r s e F l o a 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 t o t " ) . v a l u e )   +   p a r s e F l o a t ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . v a l u e ) ;  
 	 	 	 	 	 }  
 	 	 	 	 }  
 	 	 	 	  
 	 	 	 }  
 	 	 	 / / a l e r t ( ' d i s c o u n 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 s " ) . v a l u 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 ( " d i s " ) . 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 ( " N e t P r c " ) . v a l u e 	 = p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " N e t P r c " ) . v a l u e )   -   p a r s e F l o a 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 s " ) . v a l u e ) ; 	 	  
 	 	 	 }  
 	 	 	 t o t = ( p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " N e t P r c " ) . v a l u e ) ) . t o F i x e d ( 2 ) ; 	 	 	  
 	 	 	 	 	  
 	 	 	 S e t T e x t ( " C o n t e n t t o t " ,   t o t ) ;  
 	 	 } * /  
 	 	  
 	 	 / / e n d   o f   v i s h a l   s c r i p t  
 	 	  
 	 	 f u n c t i o n   c h e c k _ r a d i o b u t t o n ( )  
 	 	 {    
 	 	 	 v a r   i ;  
 	 	 	 v a r   t o t ;  
 	 	 	 f o r ( i = 0 ; i < d o c u m e n t . F o r m 1 . l e n g t h ; i + + )  
 	 	 	 {  
 	 	 	 	 i f ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . t y p e = = " r a d i o " )  
 	 	 	 	 {  
 	 	 	 	 	 i f ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . c h e c k e 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 ( " N e t P r c " ) . v a l u e 	   =   p a r s e F l o a 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 t o t " ) . v a l u e )   +   p a r s e F l o a t ( d o c u m e n t . F o r m 1 . e l e m e n t s [ i ] . v a l u 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 ( " d i s " ) . 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 ( " N e t P r c " ) . v a l u e 	 = p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " N e t P r c " ) . v a l u e )   -   p a r s e F l o a 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 s " ) . 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 ( " N e t P r c " ) . v a l u e   =   p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " N e t P r c " ) . v a l u e )   -   p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " s p d i s " ) . v a l u e ) ;  
 	 	 	  
 	 	 	 t o t = ( p a r s e F l o a t ( d o c u m e n t . g e t E l e m e n t B y I d ( " N e t P r c " ) . v a l u e ) ) . t o F i x e d ( 2 ) ; 	 	 	  
 	 	 	 	 	  
 	 	 	 S e t T e x t ( " C o n t e n t t o t " ,   t o t ) ;  
 	 	 }  
 	 	  
 	 	 / / * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *  
 	 	 f u n c t i o n   c h e c k K e y ( b t n ,   e )   {  
 	 	         i f   ( e . k e y C o d e   = =   1 3 )   {  
 	 	                 d o c u m e n t . g e t E l e m e n t B y I d ( b t n ) . c l i c k ( ) ;  
 	 	                 r e t u r n   f a l s e ;  
 	 	         }  
 	 	 }  
 	 	 / / * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *  
  
 	 	  
 	 	  
 	 	 f u n c t i o n   c h a n g e o v e r i m g ( i m g )  
 	 	 {  
 	 	 / / a l e r t ( ' v i s h a l ' ) ;  
 	 	 i m g . s r c = " i m a g e s / b u y _ h o v . g i f " ;  
 	 	 }  
 	 	  
 	 	 f u n c t i o n   c h a n g e o u t i m g ( i m g )  
 	 	 {  
 	 	 / / a l e r t ( ' v i s h a l ' ) ;  
 	 	 i m g . s r c = " i m a g e s / b u y . g i f " ; 	 	  
 	 	 }  
 	  
 	 	  
 	 	  
 	 	 f u n c t i o n   v a l i d w i s h l i s t ( i m g )  
 	 	 {  
 	 	 	 a l e r t ( ' P l e a s e   L o g i n   F i r s t   T o   A d d   P r o d u c t   I n   W i s h   L i s t . ' ) ;  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 	  
 	 	  
 f u n c t i o n   c h e c k f r o n t 1 ( v a l )  
 {  
 / / a l e r t ( v a l ) ;  
 	 v a r   c o n = 0 ;  
 	 f o r   ( v a r   i = 0 ;   i < d o c u m e n t . a s p n e t F o r m . l e n g t h ;   i + + ) {  
 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . t y p e   = =   " c h e c k b o x " ) {  
 	 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . c h e c k e d   = =   t r u e ) {  
 	 	 	 	 c o n + + ;  
 	 	 	 }  
 	 	 } 	  
 	 }  
 	 i f   ( c o n = = 0 )  
 	 {  
 	 	 i f   ( v a l   = =   " E x p o r t " ) {  
 	 	 	 a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   s e n d   w i s h l i s t ' ) ; 	 	 	  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 	 e l s e {  
 	 	         a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   s e n d   w i s h l i s t ' ) ;  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 }  
 }  
  
 f u n c t i o n   c h e c k f r o n t 2 ( v a l )  
 {  
         v a r   c o n = 0 ;  
 	 f o r   ( v a r   i   =   0 ;   i   <   d o c u m e n t . a s p n e t F o r m . l e n g t h ;   i + + ) {  
 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . t y p e   = =   " c h e c k b o x " ) {  
 	 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . c h e c k e d   = =   t r u e ) {  
 	 	 	 	 c o n + + ;  
 	 	 	 }  
 	 	 } 	  
 	 }  
 	 i f   ( c o n = = 0 ) {  
 	 	 i f   ( v a l   = =   " E x p o r t " ) {  
 	 	 	 a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   a d d   t o   c a r t ' ) ; 	 	 	  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 	 e l s e {  
 	 	         a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   a d d   t o   c a r t ' ) ;  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 } 	  
 }  
 f u n c t i o n   c h e c k f r o n t 3 ( v a l )  
 {  
 / / a l e r t ( v a l ) ;  
 	 v a r   c o n = 0 ;  
 	 f o r   ( v a r   i   =   0 ;   i   <   d o c u m e n t . a s p n e t F o r m . l e n g t h ;   i + + ) {  
 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . t y p e   = =   " c h e c k b o x " ) {  
 	 	         i f   ( d o c u m e n t . a s p n e t F o r m . e l e m e n t s [ i ] . c h e c k e d   = =   t r u e ) {  
 	 	 	 	 c o n + + ;  
 	 	 	 }  
 	 	 } 	  
 	 }  
 	 i f   ( c o n = = 0 ) {  
 	 	 i f   ( v a l   = =   " E x p o r t " ) {  
 	 	 	 a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   u p d a t e ' ) ; 	 	 	  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 	 e l s e {  
 	 	         a l e r t ( ' P l e a s e   s e l e c t   a t l e a s t   o n e   r e c o r d   f o r   u p d a t e ' ) ;  
 	 	 	 r e t u r n   f a l s e ;  
 	 	 }  
 	 }  
 }  
  
  
 f u n c t i o n   g e t v a l u e ( d d l i d ,   c u r r e n t p a g e )   {  
  
         l o c a t i o n . h r e f   =   " s e n d p a g e . a s p x ? l a n g = "   +   d d l i d . v a l u e   +   " & c u r r e n t p a g e = "   +   c u r r e n t p a g e ;  
  
         r e t u r n   f a l s e ;  
  
 }  
  
 f u n c t i o n   w i n _ o p e n ( O r d e r I d )  
 {  
         w i n d o w . o p e n ( " O r d e r D e t a i l . a s p x ? O r d e r I d = "   +   O r d e r I d   , " m y w i n d o w " , " s c r o l l b a r s = 1 , t o o l b a r = 0 , d i r e c t o r i e s = 0 , l o c a t i o n = 0 , r e s i z a b l e = 1 , w i d t h = 7 0 0 , h e i g h t = 6 0 0 " ) ;  
 }  
  
 / / / / / / o p e n   c r e d i t   c a r d   v e r i f i c a t i o n   i m a g e / / / / / / / / / / / / /  
 f u n c t i o n   v n u m b e r o p e n ( )   {  
         w i n d o w . o p e n ( " c r e d i t c a r d v i e w . a s p x " ,   " m y w i n d o w " ,   " t o o l b a r = 0 , d i r e c t o r i e s = 0 , l o c a t i o n = 0 , r e s i z a b l e = 1 , w i d t h = 6 1 0 , h e i g h t = 3 5 0 " ) ;  
         r e t u r n   f a l s e ;  
 }  
 / / / / / / e n d   c r e d i t   c a r d   v e r i f i c a t i o n   i m a g e / / / / / / / / / / / / /  
  
  
  
  
 
