2013-05-17 44 views

回答

1

ACCT變量...

$URPDetails = new UpdateRecurringPaymentsProfileRequestDetailsType(); 
    $UpdateRecurringPaymentsProfileRequestTypeObj = new UpdateRecurringPaymentsProfileRequestType(); 
    $UpdateRecurringPaymentsProfileRequestTypeObj->UpdateRecurringPaymentsProfileRequestDetails=$URPDetails; 

    $UpdateRecurringPaymentsProfileReqObj = new UpdateRecurringPaymentsProfileReq(); 
    $UpdateRecurringPaymentsProfileReqObj->UpdateRecurringPaymentsProfileRequest=$UpdateRecurringPaymentsProfileRequestTypeObj; 
    $paypalService = new PayPalAPIInterfaceServiceService(); 

     try { 
      /* wrap API method calls on the service object with a try catch */ 
      $createRPProfileResponse = $paypalService->UpdateRecurringPaymentsProfile($UpdateRecurringPaymentsProfileReqObj); 
     } catch (Exception $ex) { 
      echo 'ERROR: '.$e->getMessage()."\n"; 
      //exit; 
     } 

其中$URPDetails對象包含Credit Card DetailsProfileId

+0

感謝@Preston亞歷山大答覆.. 。我只想知道更多的一點,就是其他參數必須與我在'CreateRecurringPaymentsProfile'時設置的參數相同......還有一件事,我可以更改da下一筆交易也是? –

+0

我不認爲其他參數是必需的,你只需要更新你想要更新的內容。我不確定要改變日期 - 我相信是這樣,但在沙箱中試試看看。 –

+0

感謝@Preston Alexander它完美的作品... 其實你只需要通過'信用卡詳情'和'profile_id'就是這樣。我希望我也會得到更改日期的答案(仍在工作中)。 –

0

這是爲我工作的確切代碼