Exchange Theme API: coupons (supported)

From iThemes Codex
Revision as of 21:01, 31 July 2013 by Kopepasah (talk | contribs) (Created page with "__NOTOC__ <pre class="brush:php, gutter:false, toolbar:false"> it_exchange( 'coupons', 'supported' ) Parameters string - $context the context or context.tag combination, if...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
it_exchange( 'coupons', 'supported' )
	
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
	Boolean if coupons are supported or not.

Description

Used to check if support for coupons is enabled.

Options

'type' - Used to check if this type of coupons is supported.
	$default: false
	$options: false, cart
'return' - Used to return (instead of echo) the output.
	$default: false
	$options: true, false

Usage

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

Examples