Samples Product Information Home Page Download Pricing

Adding a Cart - PayPal

This tutorial demonstrates creating a cart using templates included with the sample data. For more information on creating a template for use with a cart, view this tutorial: Templates - Carts

Adding a PayPal cart to any template requires only a few clicks. To begin, open the HTML configuration form and click the Cart tab.

Selecting the PayPal option at the top of the form enables the Input Option selection. For a PayPal Cart you can choose either a Quantity Input Field or an Add to Cart Button.

If you select the Quantity Input Field, you can then select how many digits your customers will be able to enter.
If you select the Add to Cart button, you can then select an image file to use as a button.

To use an image file on your own server, enter the relative folder and file name. For example, if the name of the image file is buynow.gif and it is stored in the images folder, you would enter images/buynow.gif. To use an image file on another website, enter the full URL including the http prefix. For example, you could enter https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif to use a PayPal button.

Items submitted to PayPal can have two description fields. The second one is optional but you must enter the name of a column in your mySQL table for the Primary Description field.

The Description and Price fields on the Cart tab operate as Selection boxes but you can enter the name of a column if it is not on the list.
If you are configuring a cart for PHP, the selection boxes will show the labels and column names from the PHP tab.
If you are configuring a cart for HTML, the selection boxes show the names of the columns in the local database, which all begin with data and the column headers for the current category. The current category is the one which was current when you first opened the HTML Configuration form. You can change the current category by selecting a new category on the PHP tab.

For this example, the columns in the mySQL table which contain the values I want to submit to the PayPal cart are: Description, Code and Price.

For a PayPal cart, you also need to fill in the fields on the PayPal tab. You can enter either your PayPal account email address or Merchant ID in the Business field. Note, there is no field for your PayPal password. This is not required and you should never enter it in any software or web page other than when you login to your PayPal account.

You can learn more about the various URL fields on PayPal's Merchant Services pages. Briefly;
Return URL is the page on your site shown after a customer completes a purchase.
Cancel URL is the page on your site shown if a customer cancels a purchase from the checkout.
Image URL is the URL of an image to be displayed in the PayPal checkout page.
Notify URL is the page on your site which responds to Instant Payment Notifications.
Page Style is the name of a Custom Page Style saved in your PayPal account.

 

That's all it takes to add a PayPal Cart to an existing template. Click the Print button at the bottom-right of the form or exit to the Main Menu and click Print to get to the Printing Menu.
On the Printing Menu, click the www button to create the files in the Local Output Folder.

As in the previous chapter, upload the files from the Local Output Folder to the www folder on your server and enter the full URL in your browser. Using my example, that would be:

www.mySite.com/Baseball Gloves.php

 

In this screenshot, a Quantity Input box has been added to every row of the table.
Because this file is configured for a PayPal cart, each time you enter a value in a box and press the Enter key or click another box, the values are submitted to PayPal and a checkout page opens in another window.

In this screenshot, you can see the values from the Description, Code and Price columns of the mySQL table, as selected earlier on the Cart tab.

The text in the cart header: Description, Item Price and Quantity are part of the PayPal cart and cannot be changed.

The text Product under the product description is the column Header in the template itself (screenshot above) and was also submitted along with the values.

In the next chapter, I demonstrate creating a cart which accumulates products in a cart without leaving the current window.

 

Return to Tutorial Selection or Continue to the next chapter: Adding a Cart - CleverCart