一個問題,我從 https://cms.paypal.com/cms_content/US/en_US/files/developer/nvp_DoDirectPayment_php.txt約貝寶IPN
運行下載示例代碼,並得到
TIMESTAMP=2010%2d05%2d11T04%3a42%3a06Z&CORRELATIONID=ac15852d1e958&ACK=Failure&VERSION=51%2e0&BUILD=1268624&L_ERRORCODE0=10002&L_SHORTMESSAGE0=Security%20error&L_LONGMESSAGE0=Security%20header%20is%20not%20valid&L_SEVERITYCODE0=Error' (length=233)
是什麼問題呢? api用戶名? API傳遞?簽名或其他什麼?
此Infor的我填寫源碼:
// Set request-specific fields.
$paymentType = urlencode('Authorization'); // or 'Sale'
$firstName = urlencode('Nguyen');
$lastName = urlencode('Quang Trung');
$creditCardType = urlencode('Visa');
$creditCardNumber = urlencode('
4111111111111111');
$expDateMonth = '04';
// Month must be padded with leading zero
$padDateMonth = urlencode(str_pad($expDateMonth, 2, '0', STR_PAD_LEFT));
$expDateYear = urlencode('2015');
$cvv2Number = urlencode('5360 ');
$address1 = urlencode('ha noi');
$address2 = urlencode('hcm');
$city = urlencode('ha noi');
$state = urlencode('ha noi state');
$zip = urlencode('84');
$country = urlencode('viet nam'); // US or other valid country code
$amount = urlencode('900');
$currencyID = urlencode('USD'); // or other currency ('GBP', 'EUR', 'JPY', 'CAD', 'AUD')
呃...什麼?到底是什麼問題? – 2010-05-11 04:57:33
當我得到TIMESTAMP = 2010%2d05%2d11T04%3a42%3a06Z&的correlationID = ac15852d1e958&ACK =失敗&VERSION = 51%2E0&BUILD = 1268624&L_ERRORCODE0 = 10002&L_SHORTMESSAGE0 =安全%20error&L_LONGMESSAGE0 =安全%20header%20is%20not%20有效&L_SEVERITYCODE0 =錯誤'(長度= 233) ACK =失敗和查看代碼,我認爲付款失敗並不知道爲什麼停止。交易? – Chameron 2010-05-11 05:05:07