Add two difference items to shopping card-Paypal
-
Hi friends ! I need to add two or three difference items with their information but I don't know how to do that. Normal way, to put an item to shopping we just only create the button "Add to card" button and use the code from paypal as bellow.
<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="sampleEmail@domain.com">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="ITEM 001">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1000.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHostedGuest">
<input type="image" src="https://www.paypal.com/en\_GB/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.paypal.com/en\_GB/i/scr/pixel.gif" width="1" height="1">
</form>this code just only put one item to shopping card. Now, for example, i got two difference items with their information : Item one: Item name:Item 001 price :10USD item_number:001 Item two: Item name:Item 002 price :20USD item_number:002 Can anybody help me with sample code to put these two items to paypal shopping card ! Notes: I got these items and their information. I got a Checkout button. Then anybody press to Checkout button, these two items will add to shopping card of Paypal(the result will the same as we click to the "Add to card" button of item one and then continue Shopping and click to the "Add to card" button of item two). Thanks in advance !
-
Hi friends ! I need to add two or three difference items with their information but I don't know how to do that. Normal way, to put an item to shopping we just only create the button "Add to card" button and use the code from paypal as bellow.
<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="sampleEmail@domain.com">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="ITEM 001">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1000.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHostedGuest">
<input type="image" src="https://www.paypal.com/en\_GB/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.paypal.com/en\_GB/i/scr/pixel.gif" width="1" height="1">
</form>this code just only put one item to shopping card. Now, for example, i got two difference items with their information : Item one: Item name:Item 001 price :10USD item_number:001 Item two: Item name:Item 002 price :20USD item_number:002 Can anybody help me with sample code to put these two items to paypal shopping card ! Notes: I got these items and their information. I got a Checkout button. Then anybody press to Checkout button, these two items will add to shopping card of Paypal(the result will the same as we click to the "Add to card" button of item one and then continue Shopping and click to the "Add to card" button of item two). Thanks in advance !
A simpler method would be to use an associative array, like:... cart[productid] = count; filled in by the add to cart and then have the information sent to the paypal cart with the click of a second button, with a checkout button. The checkout would run a javascript to go through the array and and build the data the way that paypal likes it. Of course there needs to be more involve with a shopping cart, cancel order button, back to shopping button, remove items button, etc, etc....
-
A simpler method would be to use an associative array, like:... cart[productid] = count; filled in by the add to cart and then have the information sent to the paypal cart with the click of a second button, with a checkout button. The checkout would run a javascript to go through the array and and build the data the way that paypal likes it. Of course there needs to be more involve with a shopping cart, cancel order button, back to shopping button, remove items button, etc, etc....
Hi ! Thanks for your reply , but that is not what i need. IF your couldn't understand my question, im sorry because my english. My question is: How to send data to paypal after we got information. For Example, to send one item we use this code bellow.
<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="sampleEmail@domain.com">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="ITEM 001">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1000.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHostedGuest">
<input type="image" src="https://www.paypal.com/en\_GB/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.paypal.com/en\_GB/i/scr/pixel.gif" width="1" height="1">
</form>this code just only put one item to shopping card. In my question i 'd like to send to shopping cart(paypal shopping card) two difference items with their information : Item one: Item name:Item 001 price :10USD item_number:001 Item two: Item name:Item 002 price :20USD item_number:002 Have any ideas? Thanks in regards
-
Hi ! Thanks for your reply , but that is not what i need. IF your couldn't understand my question, im sorry because my english. My question is: How to send data to paypal after we got information. For Example, to send one item we use this code bellow.
<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="sampleEmail@domain.com">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="ITEM 001">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1000.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHostedGuest">
<input type="image" src="https://www.paypal.com/en\_GB/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.paypal.com/en\_GB/i/scr/pixel.gif" width="1" height="1">
</form>this code just only put one item to shopping card. In my question i 'd like to send to shopping cart(paypal shopping card) two difference items with their information : Item one: Item name:Item 001 price :10USD item_number:001 Item two: Item name:Item 002 price :20USD item_number:002 Have any ideas? Thanks in regards
-
Sound like you want method 2, found here https://www.paypal.com/cgi-bin/webscr?cmd=_pdn_howto_checkout_outside[^]
Dear cjoki ! Thanks for your reply. This is what i need. When i was waiting for your reply, i found another way to post items to paypal shopping card as following scribe bellow: -Using client script(js) to post each form. But this is not better than the way that you tell me.
for(var i=0;i
Thanks in advance !
modified on Wednesday, December 30, 2009 9:26 PM
-
Hi friends ! I need to add two or three difference items with their information but I don't know how to do that. Normal way, to put an item to shopping we just only create the button "Add to card" button and use the code from paypal as bellow.
<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="sampleEmail@domain.com">
<input type="hidden" name="lc" value="GB">
<input type="hidden" name="item_name" value="ITEM 001">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1000.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="button_subtype" value="products">
<input type="hidden" name="add" value="1">
<input type="hidden" name="bn" value="PP-ShopCartBF:btn_cart_LG.gif:NonHostedGuest">
<input type="image" src="https://www.paypal.com/en\_GB/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.paypal.com/en\_GB/i/scr/pixel.gif" width="1" height="1">
</form>this code just only put one item to shopping card. Now, for example, i got two difference items with their information : Item one: Item name:Item 001 price :10USD item_number:001 Item two: Item name:Item 002 price :20USD item_number:002 Can anybody help me with sample code to put these two items to paypal shopping card ! Notes: I got these items and their information. I got a Checkout button. Then anybody press to Checkout button, these two items will add to shopping card of Paypal(the result will the same as we click to the "Add to card" button of item one and then continue Shopping and click to the "Add to card" button of item two). Thanks in advance !