开发者

Paypal Return Value Question

How can I manipulate the code so that the return value is sent to my thank you page (www.website.com/thankyou.php) instead of the root homepage, while keeping everything else intact? The code 开发者_运维百科to my paypal return value is listed below.

<input type="hidden" name="return" 
    value="<?=$cfg->wwwroot."registration-confirmed-".base64_encode(serialize(array($user->id, 1)))?>">


You should use PDT (Payment Data Transfer) for this purpose.

This reference should be helpful. There are instructions on activating PDT at the bottom of the page.

Once you've setup PDT, simply change your input's name from 'return' to 'custom'.

In your code, which reads PDT data (thankyou.php), issue a redirect to 'custom' value that you'll get from Paypal PDT data. Example PHP script for PDT is here.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜