0

I am newbie to paypal. I want to integrate the direct payment in the same website. I have read the pdf file (Website payment Pro Hosted) and put some code in the html page. I have posted the code like:

<iframe name="hss_iframe" width="570px" height="540px"></iframe>
<form style="display:none" target="hss_iframe" name="form_iframe" method="post" action="https://securepayments.paypal.com/cgi-bin/acquiringweb">
   <input type="hidden" name="cmd" value="_hosted-payment">
   <input type="hidden" name="subtotal" value="50">
   <input type="hidden" name="business" value="HNZ3QZMCPBAAA">
   <input type="hidden" name="paymentaction" value="sale">
   <input type="hidden" name="template" value="templateD">
   <input type="hidden" name="return" value="https://yourwebsite.com/receipt_page.html">
</form>

but the iframe is not loading. What am I doing wrong. Am I missing any fields. I am displaying the iframe in button click.

4

1 回答 1

0

如果你只有我们看到的代码,那么什么都不做,是一个隐藏的表单,iframe当你提交它时会填写!

最后(或某处)你必须也有submit()这种形式:

<script type="text/javascript">
 document.form_iframe.submit();
</script>
于 2013-03-01T08:22:16.970 回答