add to cart
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a current site that has hundreds of products in sorted galleries. Customers submit email orders currently. I am testing the "Add to cart" button and it works great. data wise I only need to set "item_name", "item_number" and "amount" everything else is the same for every product. I would like to take the entire button code that PayPal generated for me and place it in a function/script and be able to call it with one line of code and pass my values. Is this doable? Need help, please.
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="business" value="My Account">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="add" value="1">
<input type="hidden" name="item_name" value="Commercials - Foreclosure">
<input type="hidden" name="item_number" value="ISP-Foreclosure">
<input type="hidden" name="amount" value="200.00">
<input type="hidden" name="currency_code" value="USD">
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_cart_SM.gif" border="0" name="submit" alt="Add to Cart">
</form>
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- Cart dropps items, fails to return customer to previous window in PayPal Payments Standard
- How do you dynamically pass an item name through an 'add to cart' button? in Sandbox Environment
- can't checkout with safari in PayPal Payments Standard
- Recurring payments for cart with multiple individually subscribable items? in PayPal Payments Standard
- Authorization being forced prior to Paypal Button becoming available. in PayPal Payments Standard