The Add To Cart functionality allows products to be added to the current order by accessing a web page.

Step-by-step guide

Setup:

  1. Setup the following default templates (via zAllocate.aspx):
    1. Add To Cart Success Template (can use tokens for Product in the template)
    2. Add To Cart Fail Template
  2. It is not essential to setup the templates. If they don't exist a default value is displayed:
    1. For success: "Successfully added [Product.ProductCode] to cart."
    2. For fail: "Failed to add [Product.ProductCode] to cart."


 

To add products to the current order:

  1. Login to the CSS website. You need to login otherwise the products will not be added to the order.
  2. Go to the page AddToCart.aspx and pass the following parameters:
    1. ProductCode
    2. Qty
  3. If the product is already on the order, the quantity of the product on the order is increased by the Qty specified.


For example, if the website is mywebsite.com to add the product "ABC123" to the current order go to the web page: mywebsite.com/AddToCart.aspx?ProductCode=ABC123&Qty=1


In order for the product to be added to the current order:

  • A user must be logged in.
  • The logged in user must have access to AddToCart.aspx page.
  • All the parameters must be specified and must be valid:
    • ProductCode must be an existing product.
    • Qty must be a positive integer greater than zero.


Related help