Integration Guide

Table Of Contents
Third-Party Shopping Carts – The Cart Upload Command
Integrating PayPal with Third Party Shopping Carts
5
250 September 2008 Website Payments Standard Integration Guide
quantity_2; the third item with variables like item_name_3, amount_3, and
quantity_3; and so on.
IMPORTANT: The _x values must increment by one continuously in order to be recognized.
If you skip from item #1 to item #3 without defining an item #2, the third
item will be ignored.
The minimum required HTML for your post to PayPal looks similar to the following.
EXAMPLE 5.1 HTML for Passing Individual Item Detail to PayPal
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="upload" value="1">
<input type="hidden" name="business" value="seller@designerfotos.com">
<input type="hidden" name="item_name_1" value="Item Name 1">
<input type="hidden" name="amount_1" value="1.00">
<input type="hidden" name="item_name_2" value="Item Name 2">
<input type="hidden" name="amount_2" value="2.00">
<input type="submit" value="PayPal">
</form>
Setting Currency in the Cart
All monetary variables (amount_x., shipping_x., shipping2_x, handling_x, tax_x.,
and tax_cart) are interpreted in the currency designated by the currency_code variable
posted with the payment. Because currency_code is not item-specific, there is no need to
append _
x to the currency_code variable name. If no currency_code variable is posted,
all monetary values default to U.S. Dollars.
Setting Tax on Individual Items
Use the tax_x variable to specify the tax for a particular item in the cart. For example, the
following line specifies that the tax on item 2 in the cart is 15 cents:
<INPUT TYPE="hidden" name="tax_2" value=".15">
Setting Shipping Charges on Individual Items
Use the weight_x and weight_unit variables to specify item weights if the merchant’s
profile-based shipping rates are based on weight. For example, the following lines specify the
weight of item 3 in the cart as 1.5 kg.
<INPUT TYPE="hidden" name="weight_3" value="1.5">
<INPUT TYPE="hidden" name="weight_unit" value="kgs">
Use the quantity_x variable if the merchant’s profile-based shipping rates are based on
quantity. For example, the following line specifies that the quantity for item 3 in the cart is 6.
<INPUT TYPE="hidden" name="quantity_3" value="6">