Fullscreen
Loading...
 
[Show/Hide Right Column]

Plugin Add to Cart

Introduced in Tiki5

This Wiki Plugin displays a button for adding one or more items to the shopping cart. The shopping cart is displayed and accessed using Module Cart. Once the order is placed in the shopping cart, the user is taken to Payment.

Usage and Parameters

To use this plugin in a wiki page, use the syntax:
{ADDTOCART(code= , description= , price= , href= )}{ADDTOCART}


Parameter Accepted values Default Effect Required? Since
code any text none Unique identifier for the item y
description any text none Label for the product y
price amount of currency none Price of the item y
href a valid internet address none Web page address containing information about the item. When checking out of the shopping cart, the description of the item will be a link to this page. n
label Text for the submit button. "Add to cart" Changes the text for the submit button n Tiki 6
autocheckout y or n n If turned on, will automatically checkout to the Payment screen, but does nothing if there is already something in the cart n Tiki 7
forwardafterfree ur<x>l n Will forward the user to this page after a free purchase checkout (in contrast to the payment screen in the case of a purchase where payment is required) n Tiki 7
ajaxaddtocart y or n y Uses ajax to add to cart or not n Tiki 8


Example

This code,
{ADDTOCART(description=Panama Hat, code=A150 , price=45.00)}{ADDTOCART}


Would produce:


(screenshot)
(screenshot)

The add to cart button would typically be used along with item information like below:

Image
Panama Hat
$45.00
Image


Close
noteNote

The description, inventory code and price are passed to the shopping cart when the add to cart button is clicked.


Aliases

Plugin Cart | Plugin Add to Cart | Plugin AddtoCart

Contributors to this page: Marc Laporte9146 points  , lindon137 points  , Nelson810 points  , Gregor (gta74)878 points  and xavi67984 points  .
Page last modified on Sunday 15 April, 2012 02:18:46 UTC by Marc Laporte9146 points .
The content on this page is licensed under the terms of the Creative Commons Attribution-ShareAlike License.

Site Language

Reference Guide

Keywords

These keywords serve as "hubs" for navigation within the Tiki documentation. They correspond to development keywords (bug reports and feature requests):



Tiki Newsletter

Delivered fresh to your email inbox!
Newsletter subscribe icon
Don't miss major announcements and other news!
Contribute to Tiki