【问题标题】:How to Set end date for paypal Recurring Payments With Direct Payment?如何使用直接付款设置贝宝定期付款的结束日期?
【发布时间】:2012-07-16 00:16:43
【问题描述】:

我正在使用直接付款的定期付款(https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_WPRecurringPayments#id08669F0705Z

我将参数设置如下并且工作正常,

$firstName = urlencode('MyName');//urlencode('customer_first_name');
$lastName = urlencode('MySurname');//urlencode('customer_last_name');
$creditCardType = urlencode('VISA');//urlencode('customer_credit_card_type');
$creditCardNumber = urlencode('455743552XXXXXXXX');//urlencode('customer_credit_card_number');
$expDateMonth = '07';//'cc_expiration_month';
$expDateYear = urlencode('2017');//urlencode('cc_expiration_year');
$padDateMonth = urlencode(str_pad($expDateMonth, 2, '0', STR_PAD_LEFT));
$amount =  urlencode('5');// urlencode('example_payment_amuont');
$startDate = urlencode("2012-07-17T0:0:0");
$endDate = urlencode("2012-07-21T0:0:0");

$billingPeriod = urlencode("Day");              // or "Day", "Week", "SemiMonth", "Year"
$billingFreq = urlencode("1");                      // combination of this and billingPeriod must be at most a year
$currencyID = urlencode("USD"); 

$nvpStr = "&CREDITCARDTYPE=$creditCardType".
          "&ACCT=$creditCardNumber".
          "&EXPDATE=$padDateMonth$expDateYear".
          "&FIRSTNAME=MyFirstName".
          "&LASTNAME=MyLastName".
          "&PROFILESTARTDATE=$startDate".
          "&PROFILEENDDATE=$endDate".     // **not working**
          "&BILLINGPERIOD=$billingPeriod".
          "&BILLINGFREQUENCY=$billingFreq".
          "&AMT=$amount&DESC=Test Recurring Payment";

$httpParsedResponseAr = PPHttpPost('CreateRecurringPaymentsProfile', $nvpStr);

现在我的问题是没有设置结束日期,所以如果有人知道,请回复。 我想要设置结束日期的参数。

谢谢, 基兰夏尔马。

【问题讨论】:

    标签: paypal paypal-sandbox paypal-subscriptions recurring-billing


    【解决方案1】:

    我刚刚找到了答案,

    它的“TOTALBILLINGCYCLES”将设置要发生的周期数。

    如上所述,我使用, $billingPeriod = urlencode("天"); // 周期是每天 $billingFreq = urlencode("1"); // 频率为 1。所以,每天都收款

    "&TOTALBILLINGCYCLES=15" // 现在当我使用此参数时,循环发生 15 次,因此在 15 天内收取 15 次付款。

    【讨论】:

      猜你喜欢
      • 2010-12-22
      • 2015-02-06
      • 2016-10-01
      • 2016-02-22
      • 2012-12-17
      • 2014-09-14
      相关资源
      最近更新 更多