【问题标题】:How To Make Paypal Return URL Visible Only To Payers?如何使 Paypal 返回 URL 仅对付款人可见?
【发布时间】:2015-04-16 13:59:25
【问题描述】:

我需要一个解决方案,以防止访问者在未付款或已付款但想再次访问时访问 pay-pal 返回 url(成功页面)。

如何让访问者在通过 pay-pal 付款后仅看到此 returl 网址 1 次?

感谢您的帮助

【问题讨论】:

    标签: paypal http-referer returnurl


    【解决方案1】:

    您必须在您的 PayPal 帐户中启用自动退货,否则它将忽略退货字段。

    来自文档(更新以反映新布局):

    Auto Return is turned off by default. To turn on Auto Return:
    
        1 - Log in to your PayPal account at https://www.paypal.com. The My Account Overview page appears.
        2 - Click the Profile subtab. The Profile Summary page appears.
        3 - Click the My Selling Tools link in the left column.
        4 - Under the Selling Online section, click the Update link in the row for Website Preferences. The Website Payment Preferences page appears
        5 - Under Auto Return for Website Payments, click the On radio button to enable Auto Return.
        6 - In the Return URL field, enter the URL to which you want your payers redirected after they complete their payments. NOTE: PayPal checks the Return URL that you enter. If the URL is not properly formatted or cannot be validated, PayPal will not activate Auto Return.
        7 - Scroll to the bottom of the page, and click the Save button.
    

    IPN 用于即时付款通知。与自动返回相比,它会为您提供更可靠/有用的信息。

    IPN 的文档在这里:https://www.x.com/sites/default/files/ipnguide.pdf

    IPN 在线文档:https://developer.paypal.com/docs/classic/ipn/gs_IPN/

    一般的程序是您在请求中传递一个 notify_url 参数,并设置一个处理和验证 IPN 通知的页面,PayPal 将向该页面发送请求以在付款/退款/等时通知您。经过。该 IPN 处理程序页面将是更新数据库以将订单标记为已付款的正确位置。

    【讨论】:

    • 感谢您的回答,我已经调整了 paypal ipn,paypal 自动返回 pdt 选项我只需要访问者或当前成员不应该到达/知道成功页面的确切 url(自动返回 url)例如:www .domain.com/payment-successful 我希望每次有人付款时它看起来都不同,例如:www.domain.com/asd7a8sd7a89sd7a9s87da9sd7a9(加密)或者它没有加密但只有在贝宝付款后才能查看,如果新访客或旧现有会员知道成功页面链接(自动返回 url),这个人仍然不应该查看它(它给出错误或重定向主页)
    • 我正在使用 PayPal 就像你需要的一样,如果买家直接返回成功页面,比如说几个小时后,它会看到一个错误(令牌错误...)。代替那个错误,您可以编写成功页面,以便在发生错误时将用户重定向到产品页面。
    • 我的成功页面(购买完成后从贝宝返回 url)是一个 wordpress 页面。无论用户登录与否,或购买与否,目前每个人都可以看到。我需要它只有在贝宝付款后才能访问。你能给我一些建议吗?感谢您的支持
    • @bilal 这是错误的。你需要为你的返回页面创建一个 php 脚本,看看这里的例子paysketch.com/setup-paypal-pdt这里也有一个完整的项目github.com/thenbrent/paypal-digital-goods-php-examples
    猜你喜欢
    • 1970-01-01
    • 2016-04-07
    • 2015-12-23
    • 2016-07-06
    • 2013-08-29
    • 2010-12-03
    • 2021-06-22
    • 2018-12-12
    • 2015-10-17
    相关资源
    最近更新 更多