0
votes

The title is pretty much self-explanatory, when i receive the ?token containing all that shinanigan and make call GetShippingDetails i only get part of the variables that are supposed to come through - but no error comes off either;

My "test account" (the buyer) has all address, name, phone and whatnot configured, but those variables don't come trhu. All i get is the $resArray["email"] and $resArray["firstName"] all others come out as undefined index. I'm using the default paypal wizard files.

Anyone jumped over this fence yet?


So, i tried print_r($resArray) which returned this:

Array ( [TOKEN] => EC-79Y444941M2394358 [CHECKOUTSTATUS] => PaymentActionNotInitiated [TIMESTAMP] => 2012-06-05T11:08:41Z [CORRELATIONID] => 1c27fb16fd35 [ACK] => Success [VERSION] => 64 [BUILD] => 2975009 [EMAIL] => [email protected] [PAYERID] => M5FLRP2QZLGHG [PAYERSTATUS] => verified [FIRSTNAME] => Mosh [LASTNAME] => Mage [COUNTRYCODE] => US [CURRENCYCODE] => EUR [AMT] => 9.00 [ITEMAMT] => 9.00 [SHIPPINGAMT] => 0.00 [HANDLINGAMT] => 0.00 [TAXAMT] => 0.00 [INSURANCEAMT] => 0.00 [SHIPDISCAMT] => 0.00 [L_NAME0] => HAMS [L_QTY0] => 1 [L_TAXAMT0] => 0.00 [L_AMT0] => 9.00 [L_DESC0] => descricao [L_ITEMWEIGHTVALUE0] => 0.00000 [L_ITEMLENGTHVALUE0] => 0.00000 [L_ITEMWIDTHVALUE0] => 0.00000 [L_ITEMHEIGHTVALUE0] => 0.00000 [PAYMENTREQUEST_0_CURRENCYCODE] => EUR [PAYMENTREQUEST_0_AMT] => 9.00 [PAYMENTREQUEST_0_ITEMAMT] => 9.00 [PAYMENTREQUEST_0_SHIPPINGAMT] => 0.00 [PAYMENTREQUEST_0_HANDLINGAMT] => 0.00 [PAYMENTREQUEST_0_TAXAMT] => 0.00 [PAYMENTREQUEST_0_INSURANCEAMT] => 0.00 [PAYMENTREQUEST_0_SHIPDISCAMT] => 0.00 [PAYMENTREQUEST_0_INSURANCEOPTIONOFFERED] => false [L_PAYMENTREQUEST_0_NAME0] => HAMS [L_PAYMENTREQUEST_0_QTY0] => 1 [L_PAYMENTREQUEST_0_TAXAMT0] => 0.00 [L_PAYMENTREQUEST_0_AMT0] => 9.00 [L_PAYMENTREQUEST_0_DESC0] => descricao [L_PAYMENTREQUEST_0_ITEMWEIGHTVALUE0] => 0.00000 [L_PAYMENTREQUEST_0_ITEMLENGTHVALUE0] => 0.00000 [L_PAYMENTREQUEST_0_ITEMWIDTHVALUE0] => 0.00000 [L_PAYMENTREQUEST_0_ITEMHEIGHTVALUE0] => 0.00000 [PAYMENTREQUESTINFO_0_ERRORCODE] => 0 )

And again, all the undefined came about:

Notice: Undefined index: SALUTATION in D:\Program Files\EasyPHP-5.3.9\www\YSHLM\paypal-landing.php on line 43

Notice: Undefined index: MIDDLENAME in D:\Program Files\EasyPHP-5.3.9\www\YSHLM\paypal-landing.php on line 45

this goes on for SUFFIX, BUSINESS, PAYMENTREQUEST_0_SHIPTONAME, PAYMENTREQUEST_0_SHIPTOSTREET, PAYMENTREQUEST_0_SHIPTOSTREET2, PAYMENTREQUEST_0_SHIPTOCITY, PAYMENTREQUEST_0_SHIPTOSTATE, PAYMENTREQUEST_0_SHIPTOCOUNTRYCODE, PAYMENTREQUEST_0_SHIPTOZIP, ADDRESSSTATUS, INVNUM and PHONENUM.

Could this be a configuration error on the sandbox.paypal.com? I went and double checked anyway but i do have (at least) shipping address (to where the merchendise needs to go, right?) set and saved. The address is not real but then again do i need a real one?

2
@MoshMage-I have same issue?how can i solve it?please help meShanu k k

2 Answers

1
votes

I really wish Paypal would clean up their docs, it's completely different from when I last worked with them. Anyways just looking at my old code here are the variables I was able pull with GetShippingDetails, you could always use print_r($resArray); to see everything as well.

EMAIL
PAYERID
PAYERSTATUS
SALUTATION
FIRSTNAME
MIDDLENAME
LASTNAME
SUFFIX
COUNTRYCODE
BUSINESS
SHIPTONAME
SHIPTOSTREET
SHIPTOSTREET2
SHIPTOCITY
SHIPTOSTATE
SHIPTOCOUNTRYCODE
SHIPTOZIP
ADDRESSSTATUS
INVNUM
PHONENUM

Actually just found this: https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_nvp_r_GetBillingAgreementCustomerDetails I guess paypal changed their method name?

0
votes

on my CallShortcutExpressCheckout i had the NOSHIPPING=1 flag defined. that was the problem. I still need to check some of the variables, but none inflict a problem with the cart system.

Thanks for trying, @David Nguyen, it seems I'm my own Brutus.