src/ShopBundle/objects/db/TShopPaymentHandler/TShopPaymentHandlerPayPalExpress.class.php
protected function GetUserDataFromPayPalData(&$aBilling, &$aShipping)
    {
        $sCountryIsoCode = 'de';
        if (array_key_exists('SHIPTOCOUNTRYCODE', $this->aCheckoutDetails)) {
            $sCountryIsoCode = $this->aCheckoutDetails['SHIPTOCOUNTRYCODE'];
        }

        $oShippingCountry = TdbDataCountry::GetInstanceForIsoCode($sCountryIsoCode);

        $sMail = (array_key_exists('EMAIL', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['EMAIL'] : '';
        $sCompany = (array_key_exists('BUSINESS', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['BUSINESS'] : '';
        //$sDataExtranetSalutationId = (array_key_exists('',$this->aCheckoutDetails)) ? $this->aCheckoutDetails[''] : '';
        $sFirstname = (array_key_exists('FIRSTNAME', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['FIRSTNAME'] : '';
        $sLastname = (array_key_exists('LASTNAME', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['LASTNAME'] : '';

        $sStreet = (array_key_exists('SHIPTOSTREET', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOSTREET'] : '';
        $sCity = (array_key_exists('SHIPTOCITY', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOCITY'] : '';
        $sPostalcode = (array_key_exists('SHIPTOZIP', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOZIP'] : '';
        $sTelefon = (array_key_exists('PHONENUM', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['PHONENUM'] : '';
        $addressAdditionalInfo = (array_key_exists('SHIPTOSTREET2', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOSTREET2'] : '';

        $aBilling = array('name' => $sMail, 'email' => $sMail, 'company' => $sCompany, 'data_extranet_salutation_id' => '', 'firstname' => $sFirstname, 'lastname' => $sLastname, 'street' => $sStreet, 'streenr' => '', 'city' => $sCity, 'postalcode' => $sPostalcode, 'telefon' => $sTelefon, 'fax' => '', 'data_country_id' => $oShippingCountry->id, 'address_additional_info' => $addressAdditionalInfo);

        $sShippingLastName = (array_key_exists('SHIPTONAME', $this->aCheckoutDetails) && '' != $this->aCheckoutDetails['SHIPTONAME']) ? $this->aCheckoutDetails['SHIPTONAME'] : $sFirstname.' '.$sLastname;

        $aShipping = array('company' => $sCompany, 'data_extranet_salutation_id' => '', 'firstname' => '', 'lastname' => $sShippingLastName, 'street' => $sStreet, 'streenr' => '', 'city' => $sCity, 'postalcode' => $sPostalcode, 'telefon' => $sTelefon, 'fax' => '', 'data_country_id' => $oShippingCountry->id, 'address_additional_info' => $addressAdditionalInfo);

        $this->postProcessBillingAndShippingAddress($aBilling, $aShipping);
    }
protected function GetUserDataFromPayPalData(&$aBilling, &$aShipping)
    {
        $sCountryIsoCode = 'de';
        if (array_key_exists('SHIPTOCOUNTRYCODE', $this->aCheckoutDetails)) {
            $sCountryIsoCode = $this->aCheckoutDetails['SHIPTOCOUNTRYCODE'];
        }

        $oShippingCountry = TdbDataCountry::GetInstanceForIsoCode($sCountryIsoCode);

        $sMail = (array_key_exists('EMAIL', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['EMAIL'] : '';
        $sCompany = (array_key_exists('BUSINESS', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['BUSINESS'] : '';
        //$sDataExtranetSalutationId = (array_key_exists('',$this->aCheckoutDetails)) ? $this->aCheckoutDetails[''] : '';
        $sFirstname = (array_key_exists('FIRSTNAME', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['FIRSTNAME'] : '';
        $sLastname = (array_key_exists('LASTNAME', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['LASTNAME'] : '';

        $sStreet = (array_key_exists('SHIPTOSTREET', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOSTREET'] : '';
        $sCity = (array_key_exists('SHIPTOCITY', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOCITY'] : '';
        $sPostalcode = (array_key_exists('SHIPTOZIP', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOZIP'] : '';
        $sTelefon = (array_key_exists('PHONENUM', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['PHONENUM'] : '';
        $addressAdditionalInfo = (array_key_exists('SHIPTOSTREET2', $this->aCheckoutDetails)) ? $this->aCheckoutDetails['SHIPTOSTREET2'] : '';

        $aBilling = array('name' => $sMail, 'email' => $sMail, 'company' => $sCompany, 'data_extranet_salutation_id' => '', 'firstname' => $sFirstname, 'lastname' => $sLastname, 'street' => $sStreet, 'streenr' => '', 'city' => $sCity, 'postalcode' => $sPostalcode, 'telefon' => $sTelefon, 'fax' => '', 'data_country_id' => $oShippingCountry->id, 'address_additional_info' => $addressAdditionalInfo);

        $sShippingLastName = (array_key_exists('SHIPTONAME', $this->aCheckoutDetails) && '' != $this->aCheckoutDetails['SHIPTONAME']) ? $this->aCheckoutDetails['SHIPTONAME'] : $sFirstname.' '.$sLastname;

        $aShipping = array('company' => $sCompany, 'data_extranet_salutation_id' => '', 'firstname' => '', 'lastname' => $sShippingLastName, 'street' => $sStreet, 'streenr' => '', 'city' => $sCity, 'postalcode' => $sPostalcode, 'telefon' => $sTelefon, 'fax' => '', 'data_country_id' => $oShippingCountry->id, 'address_additional_info' => $addressAdditionalInfo);

        $this->postProcessBillingAndShippingAddress($aBilling, $aShipping);
    }
protected function GetUserDataFromPayPalData ( & $ aBilling , & $ aShipping ) { $ sCountryIsoCode = 'de' ; if ( array_key_exists ( 'SHIPTOCOUNTRYCODE' , $ this -> aCheckoutDetails ) ) { $ sCountryIsoCode = $ this -> aCheckoutDetails [ 'SHIPTOCOUNTRYCODE' ] ; } $ oShippingCountry = TdbDataCountry :: GetInstanceForIsoCode ( $ sCountryIsoCode ) ; $ sMail = ( array_key_exists ( 'EMAIL' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'EMAIL' ] : '' ; $ sCompany = ( array_key_exists ( 'BUSINESS' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'BUSINESS' ] : '' ; //$sDataExtranetSalutationId = (array_key_exists('',$this->aCheckoutDetails)) ? $this->aCheckoutDetails[''] : ''; $ sFirstname = ( array_key_exists ( 'FIRSTNAME' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'FIRSTNAME' ] : '' ; $ sLastname = ( array_key_exists ( 'LASTNAME' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'LASTNAME' ] : '' ; $ sStreet = ( array_key_exists ( 'SHIPTOSTREET' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'SHIPTOSTREET' ] : '' ; $ sCity = ( array_key_exists ( 'SHIPTOCITY' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'SHIPTOCITY' ] : '' ; $ sPostalcode = ( array_key_exists ( 'SHIPTOZIP' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'SHIPTOZIP' ] : '' ; $ sTelefon = ( array_key_exists ( 'PHONENUM' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'PHONENUM' ] : '' ; $ addressAdditionalInfo = ( array_key_exists ( 'SHIPTOSTREET2' , $ this -> aCheckoutDetails ) ) ? $ this -> aCheckoutDetails [ 'SHIPTOSTREET2' ] : '' ; $ aBilling = array ( 'name' => $ sMail , 'email' => $ sMail , 'company' => $ sCompany , 'data_extranet_salutation_id' => '' , 'firstname' => $ sFirstname , 'lastname' => $ sLastname , 'street' => $ sStreet , 'streenr' => '' , 'city' => $ sCity , 'postalcode' => $ sPostalcode , 'telefon' => $ sTelefon , 'fax' => '' , 'data_country_id' => $ oShippingCountry -> id , 'address_additional_info' => $ addressAdditionalInfo ) ; $ sShippingLastName = ( array_key_exists ( 'SHIPTONAME' , $ this -> aCheckoutDetails ) && '' != $ this -> aCheckoutDetails [ 'SHIPTONAME' ] ) ? $ this -> aCheckoutDetails [ 'SHIPTONAME' ] : $ sFirstname . ' ' . $ sLastname ; $ aShipping = array ( 'company' => $ sCompany , 'data_extranet_salutation_id' => '' , 'firstname' => '' , 'lastname' => $ sShippingLastName , 'street' => $ sStreet , 'streenr' => '' , 'city' => $ sCity , 'postalcode' => $ sPostalcode , 'telefon' => $ sTelefon , 'fax' => '' , 'data_country_id' => $ oShippingCountry -> id , 'address_additional_info' => $ addressAdditionalInfo ) ; $ this -> postProcessBillingAndShippingAddress ( $ aBilling , $ aShipping ) ; }
updates teh aBilling and aShipping arrays with the user billing and shipping
info returned from paypal.

@param array $aBilling
@param array $aShipping
updates teh aBilling and aShipping arrays with the user billing and shipping info returned from paypal .