For more information... RTFM!

You are not logged in

Powered by Interchange version 5.7.0


Get a list of all of the items that are in the visitor's shopping cart.


  • [item-list cart] ... [/item-list]

Parameter Description Default
cart Cart name to use. main
name Alias for cart. main
reverse Reverse the order of the cart items. No
sort Sort the cart items using options specified here None

Suppress any output text that would ordinarily be returned from this tag.  (This universal parameter was introduced with Interchange version 5.5.2.)


Parse Interchange tags, included in the body text, before this container tag executes.


Process any Interchange tags found in the text output from this tag.


The following parameters are also available to this tag:

Parameter Description Default
form Arguments for use in [more-list] URIs. None
label Label for use with multiple simultaneously-active search objects. current
more_template Override the default [more-list] display template.  
prefix Override the "PREFIX" used by the various [PREFIX-*] sub-tags. item
safe_data Allow the "[" character to remain intact in returned data. No

See the search parameters page for more parameters.  Note that you must use the two-character short code, rather than the full name, with parameters listed on that page.  Here is a quick list of some of the search parameters that are useful in this context:

Parameter Description Default
fm Return results starting from the specified row number. 0
ml Number of results to display on each page. 50
mm Maximum number of results to display. None
sp Page that should be used to display the results. results
st Set to "db" for a database search or "text" for a text file search. None


Tag expansion example

[item-list][item-code], [/item-list]
00-0010, 00-0020,


The [item-list] tag loops over each of the items in the visitor's shopping cart.  This container tag's body text is run for each item in the cart, thereby building up a buffer of text, HTML or whatever is required..

This tag is usually used to format basket display pages and mini-basket components.

You may use any of the loop sub-tags in this container tag's body text.  The default PREFIX for this container tag is "item".

The order in which the cart items are displayed can be influenced by either the reverse or the sort parameter, or by using the [sort] pseudo-tag.



A website may define more than one cart.  Each cart is referenced by name.  The default cart's name is "main".  Use this parameter if you want to use a different different cart.


If set true, the cart items will be iterated in reverse order.  This may be useful if you want to show the latest additions at the top of the display.


The cart items can be sorted into a specific order using this parameter.  This parameter expects sort options to be specified in a specific manner, as explained here.


You can use this to pass one or more form variables in the pagination links of a [more-list].  For example, use form="foo=bar" to include "foo=bar", as a URI argument in each of the pagination links.



Form variables, specified using this parameter, will not be available to the [cgi] tag in the initial result set.  This is because the query returns the first page directly and no pagination link will have been followed.


If you are setting up multiple simultaneously-active search objects within a page, then this allows you to distinguish between them.  The default label is "current".  Most people will not need this.


Override the default display template value, used by the [more-list] sub-tag.


Setting "prefix=foo" overrides the "PREFIX" used by the various [PREFIX-*] sub-tags, and also by the [PREFIX-quote] container.

The default "prefix" is "item".


Setting "safe_data=1" allows the [sql-data] and [sql-param] sub-tag (etc.) to return values containing the "[" character.



Beware of reparsing issues.  You should not use "safe_data" unless you really need it and you know what you're doing.

See also

Category:  Interchange tags
Last modified by: Kevin Walsh
Modification date: Saturday 3 March 2007 at 4:48 AM (EST)
Home  |  Legal nonsense  |  Privacy policy  |  Donations  |  Contact us