Show
Ignore:
Timestamp:
06/11/2008 08:24:54 AM (5 months ago)
Author:
zombor
Message:

Fixing some bad paypal code.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/system/libraries/drivers/Payment/Paypal.php

    r2593 r2817  
    3131                'RETURNURL'     => FALSE, 
    3232                'CANCELURL'     => FALSE, 
    33                 'PAYPALURL'     => FALSE, 
    34  
    35                 'PAYMENTACTION' => FALSE, 
    3633 
    3734                'CURRENCYCODE'  => FALSE, // default is USD - only required if other currency needed 
     
    5754                'CURRENCYCODE'  => '', // default is USD - only required if other currency needed 
    5855                'MAXAMT'        => '', 
    59  
    60                 'PAYMENTACTION' => '', // 'Sale', 'Authorization' or 'Order' see: https://www.paypal.com/en_US/ebook/PP_NVPAPI_DeveloperGuide/Appx_fieldreference.html#2557853 
    6156 
    6257                // USERACTION defaults to 'continue' 
     
    132127                'METHOD'        => 'DoExpressCheckoutPayment', 
    133128                'TOKEN'         => '', // this token is retrieved from the response to the setExpressCheckout call 
    134                 'PAYMENTACTION' => '', // 'Sale', 'Authorization' or 'Order' see: https://www.paypal.com/en_US/ebook/PP_NVPAPI_DeveloperGuide/Appx_fieldreference.html#2557853 
    135129                'PAYERID'       => '', 
    136130                'AMT'           => '', // payment amount - MUST include decimal point followed by two further digits 
     
    218212 
    219213                $this->test_mode = $config['test_mode']; 
     214                $this->api_connection_fields['PAYPALURL'] = 'https://www.paypal.com/webscr&cmd=_express-checkout&token='; 
    220215 
    221216                if ($this->test_mode) 
     
    226221 
    227222                        $this->api_connection_fields['ENDPOINT']     = $config['SANDBOX_ENDPOINT']; 
    228                         $this->api_connection_fields['PAYPALURL']    = $config['SANDBOX_PAYPALURL']; 
     223                        $this->api_connection_fields['PAYPALURL']    = 'https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_express-checkout&token='; 
    229224                } 
    230225 
     
    248243                        { 
    249244                                case 'amount': 
    250                                 $key = 'AMT'; 
    251                                 break; 
     245                                        $key = 'AMT'; 
     246                                        break; 
    252247                                default: 
    253248                        }