Exchange Theme API: coupons (remove)

From IThemes Codex
(Difference between revisions)
Jump to: navigation, search
(Created page with "__NOTOC__ <pre class="brush:php, gutter:false, toolbar:false"> it_exchange( 'coupons', 'remove', array( 'option' => 'value' ) ) Parameters string - $context the context or ...")
 
 
Line 14: Line 14:
 
Used to output the element to remove the coupon.
 
Used to output the element to remove the coupon.
  
'before' => '',
 
'after'  => '',
 
'class'  => 'remove-coupon',
 
'type'  => false,
 
'format' => 'link',
 
'label'  => '&times;',
 
 
 
==Options==
 
==Options==
 
<pre class="brush:php, gutter:false, toolbar:false">
 
<pre class="brush:php, gutter:false, toolbar:false">

Latest revision as of 17:20, August 1, 2013

it_exchange( 'coupons', 'remove', array( 'option' => 'value' ) )
	
Parameters
	string - $context the context or context.tag combination, if context.tag is used, the tag parameter can be omitted.
	string - $tag the tag, can be hyphenated or not.
	mixed  - $options associative array, or url-style name=value pairs separated by ampersands (&).
Returns
	The remove coupon element.

Description

Used to output the element to remove the coupon.

Options

'format' - Used to sets the format of the output.
	$default: 'link'
	$options: link, checkbox
'class' - Used to set the class of the link.
	$default: 'remove-coupon'
	$options: Any valid class name.
'type' - Set the type.
	$default: false
	$options: false
'label' - Used to set the label of the link.
	$default: '×'
	$options: Any valid text.
'before' - Used to output content before the remove link.
	$default: empty
	$options: Any valid html.
'after' - Used to output content after the remove link.
	$default: empty
	$options: Any valid html.
'return' - Used to return (instead of echo) the output.
	$default: false
	$options: true, false

Usage

<?php it_exchange( 'coupons', 'remove', array( 'type' => 'cart' ) ) ); ?>

Examples

Personal tools
Namespaces
Variants
Actions
iThemes Codex
Codex Navigation
Toolbox