Buy now button does not work - error
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I have the following Buy Now button in my page:
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick" />
<input type="hidden" name="hosted_button_id" value="paypalID" />
<table>
<tr><td><input type="hidden" name="on0" value="Packages" /> </td></tr><tr><td><select name="os0">
<option value="€25 refill">€25 mytext - €0.31</option>
<option value="€50.5 refill">€50.5 mytext - €0.31</option>
<option value="€202 refill">€202 mytext - €0.31</option>
</select> </td></tr>
</table>
<input type="hidden" name="currency_code" value="EUR" />
<input type="hidden" name="custom" value="mytext" />
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!" />
<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1" />
</form>
I've changed the automatically generated text at the 'mytext' places and deleted the heading text for the options. Furthermore added custom field for a passthrough value.
When I click on the button (hosted on PayPal, actual ID value is only here replaced by 'paypalID') I reach paypal but got the following error:
"PayPal cannot process this transaction because of a problem with the seller's website. Please contact the seller directly to resolve this problem."
No details, not even an error ID. How can I debug it further? Where can I get additional info about such an error?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I wish I could help you but I have the same problem so I'm posting here to see if anyone knows...
If I copy and paste the code into my joomla based site (I have the editor set to not strip code or modify it in any way). The first time I paste it in and save the page it works fine. Whenever I open that page to edit anything else (no intentional code modifications), I get the same error. I can't figure out what is being changed in the code or why. Maybe you should try that. Paste in the code, save and then try the button.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Having a similar problem but with an add to cart button. Would love some help on this!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi oorgoo, brewhardware and HighRes,
Looking at oorgoo's code, it looks like the value attributes in the option elements could be causing the problem. If those values were changed, our system would not know what prices to assign to each option. I recommend recreating the button and be sure not to change those "value" variables.
To get a better idea of how this works, you can uncheck "Save button at PayPal" under Step 2 of the button creator, then click "Remove Code Protection" on the page that displays the button code. All the variables that would normally be included in the hosted_button_id are now included in the button code. That way you can make changes without having to worry about a change conflicting with values already associated with the button in the PayPal system. I hope this makes sense.
For example, here's a test add to cart button I made that is not PayPal hosted or code protected:
(the business variable has been changed to "mytext" and would normally set to the email address on your PayPal account or your secure merchant ID.
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="business" value="mytext">
<input type="hidden" name="lc" value="US">
<input type="hidden" name="item_name" value="Test">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="no_note" value="0">
<input type="hidden" name="cn" value="Add special instructions to the seller">
<input type="hidden" name="no_shipping" value="2">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHosted">
<table>
<tr><td><input type="hidden" name="on0" value="Packages">Packages</td></tr><tr><td><select name="os0">
<option value="€25 refill">Option 1 €25.00 EUR</option>
<option value="€50.5 refill">Option 2 €50.50 EUR</option>
<option value="€202 refill">Option 3 €202.00 EUR</option>
</select> </td></tr>
</table>
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="option_select0" value="€25 refill">
<input type="hidden" name="option_amount0" value="25.00">
<input type="hidden" name="option_select1" value="€50.5 refill">
<input type="hidden" name="option_amount1" value="50.50">
<input type="hidden" name="option_select2" value="€202 refill">
<input type="hidden" name="option_amount2" value="202.00">
<input type="hidden" name="option_index" value="0">
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_cart_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>
Notice how all the option_selectn and option_amountn variables are being set in the code. The values for the option_selectn need to match with the values for <option> lines above that. Since you can't modify those added variables after a hosted button is created, any change to the option variables would mean the system doesn't know what price to assign to each option.
Another option would be to recreate the button with all of the information set up front so the code doesn't have to be modified after it's generated.
I hope this helps! 🙂
brewhardware and HighRes, if this doesn't help with your buttons, feel free to post your button code so the community can test.
- Frank
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- Paypal charged wrong account in About Payments (Archive)
- cant dend money to seller via PayPal credit in About Payments (Archive)
- Porblema with , REST API apps. please help in About Settings (Archive)
- Wow, the help you get from paypal sure is terrible. in About Settings (Archive)
- Currency Conversion not working in Paypal Subscription button in About Payments (Archive)