Safari、iFrame、将地址栏更改为 iFrame URL
Safari, iFrame, changing Address Bar to iFrame URL
我有一个表单,当您单击“提交”时,它会转到另一个 .php 页面,该页面的全部目标是加载带有 URL 指向 paypal 的 iFrame。这使我们能够让客户输入 CC 信息,而无需他们的 CC 信息接触我们的服务器(以保持合规性)
我遇到的问题完全是 iPad 上的 Safari(可能 iPhone,但我还没有测试过)
单击表单按钮后加载第二页时,它会将地址栏更改为 iFrame 的 URL,而不是加载带有其 URL 的 iFrame。
这会导致页面给出有关 securetokenID 错误的错误,导致客户无法继续。
我有一封关于这个问题的电子邮件到 paypal,但我想我会在这里停下来询问是否有其他人有这个问题并且知道解决它的方法。
我找到的所有帖子都是 2013 年关于类似问题的帖子,他们声称贝宝不支持移动设备,您必须通过其他方式访问贝宝。我希望自 2 年后现在有一个更简单的解决方案可以让 Safari 在页面中加载 iFrame 而不是将地址栏更改为 iFrame URL.
iFrame 代码如下所示:
<iframe src="https://pilot-payflowlink.paypal.com?SECURETOKENID=vvqhqn8hwfi9poo2zcbm4xi4xevaq7hbfbyz&SECURETOKEN=8WjBh0buSd0WLc0FJRSOXwgS9" id="paypal_iframe" name="paypal_iframe" scrolling="no" width="480px" height="540px"></iframe>
因此,当我单击表单按钮时,它应该会转到 signup_2.php,它会转瞬即逝,然后 "redirects" 会转到 iframe 中的 URL,这当然不能正确加载,因为 paypal 需要它在 iframe 中。
这只发生在 Apple 移动设备上的 Safari 中。
感谢您的帮助。
从 PayPal 开发者网站,这里有一些关于托管结帐页面和移动优化的信息:
PayPal’s hosted checkout pages are mobile optimized for iPhone, iPod and Android devices. This mobile optimized experience is available for all 3 Layout templates A, B and C. In the case of Layouts A and B, PayPal will auto-detect if the checkout page is being viewed from a supported mobile browser and will redirect to the mobile optimized checkout page. For Layout C, PayPal does not automatically redirect mobile users to a mobile optimized flow. The reason is that if PayPal automatically showed a mobile optimized embedded template, within a merchant web page that may not be mobile optimized, this can create unexpected and undesirable results. To display the mobile checkout page for Layout C, you must detect the supported mobile browser and then explicitly pass the form post parameter: TEMPLATE=MOBILE.
我有一个表单,当您单击“提交”时,它会转到另一个 .php 页面,该页面的全部目标是加载带有 URL 指向 paypal 的 iFrame。这使我们能够让客户输入 CC 信息,而无需他们的 CC 信息接触我们的服务器(以保持合规性)
我遇到的问题完全是 iPad 上的 Safari(可能 iPhone,但我还没有测试过)
单击表单按钮后加载第二页时,它会将地址栏更改为 iFrame 的 URL,而不是加载带有其 URL 的 iFrame。
这会导致页面给出有关 securetokenID 错误的错误,导致客户无法继续。
我有一封关于这个问题的电子邮件到 paypal,但我想我会在这里停下来询问是否有其他人有这个问题并且知道解决它的方法。
我找到的所有帖子都是 2013 年关于类似问题的帖子,他们声称贝宝不支持移动设备,您必须通过其他方式访问贝宝。我希望自 2 年后现在有一个更简单的解决方案可以让 Safari 在页面中加载 iFrame 而不是将地址栏更改为 iFrame URL.
iFrame 代码如下所示:
<iframe src="https://pilot-payflowlink.paypal.com?SECURETOKENID=vvqhqn8hwfi9poo2zcbm4xi4xevaq7hbfbyz&SECURETOKEN=8WjBh0buSd0WLc0FJRSOXwgS9" id="paypal_iframe" name="paypal_iframe" scrolling="no" width="480px" height="540px"></iframe>
因此,当我单击表单按钮时,它应该会转到 signup_2.php,它会转瞬即逝,然后 "redirects" 会转到 iframe 中的 URL,这当然不能正确加载,因为 paypal 需要它在 iframe 中。
这只发生在 Apple 移动设备上的 Safari 中。
感谢您的帮助。
从 PayPal 开发者网站,这里有一些关于托管结帐页面和移动优化的信息:
PayPal’s hosted checkout pages are mobile optimized for iPhone, iPod and Android devices. This mobile optimized experience is available for all 3 Layout templates A, B and C. In the case of Layouts A and B, PayPal will auto-detect if the checkout page is being viewed from a supported mobile browser and will redirect to the mobile optimized checkout page. For Layout C, PayPal does not automatically redirect mobile users to a mobile optimized flow. The reason is that if PayPal automatically showed a mobile optimized embedded template, within a merchant web page that may not be mobile optimized, this can create unexpected and undesirable results. To display the mobile checkout page for Layout C, you must detect the supported mobile browser and then explicitly pass the form post parameter: TEMPLATE=MOBILE.