Using the PayPal website, I created a drop down list of items for a website and an "add to cart button":
<form target="paypal" 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="J793S02EGAQ92">
<table>
<tr>
<td>
<input type="hidden" name="on0" value="Capacity">
<center>Select Size:</center>
</td>
</tr>
<tr>
<td>
<select id="selectDirect" name="os0">
<option value="Small">SMALL - $10</option>
<option value="Medium">MEDIUM - $20</option>
<option value="Large">LARGE - $30</option>
</select>
</td>
</tr>
</table>
<input type="hidden" name="currency_code" value="GBP">
<center><input type="image" src="./add-to-shopping-cart.png" border="0" name="submit" alt="Add to Cart" width=150px></center>
<img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1">
</form>
My problem is that they limit the number of dropdown items to 10, but I need more like 20. Apparently, this is possible, but the code has to be created manually and not automatically generated from PayPal website.
I'm not really sure what this means - I know how to manually add more lines to the dropdown button by just adding them in the HTML. But I assume that it's a little more complicated that, as the items need to link back to PayPal somehow.
I found this post about it, but it's 5 years old so it seems like some of the advice is out of date.
If anyone could offer any advice that would be appreciated. Even just an explanation of how my HTML tells PayPal what to add to the cart etc.
PayPal offers three options by default, but you can add more by clicking "Add Another Option" or reduce it to two by clicking "Remove Option."
Click Tools at the top of the page to navigate to the My Saved Buttons page. Then, click the PayPal Buttons item on the Tools page; Note: If you do not see Tools at the top of the page, click the Merchant Services tab, then click My saved buttons under Tools and settings on the right.
There is a limitation for the dropdown menu for hosted button. It will only allow up to 10 item.
You will need to code the button mannualy.
To make it easy, you can create the button from your PayPal account and on STEP 2, UNCHECK the "Save Button at PayPal".
When you retrieve the code, click "Remove code protection" this will give you a free-text code. You can then add more item into the dropdown list.
The data will be transferred back to PayPal eventhough the customer choose the additional item in the dropdown list.
<option>
s from the second set of options into the HTML for the first one, it should have the correct option values that PayPal wants for that os0
field used in the dropdown you showed as an exampleIf you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With