active_coupons
Lists the active discount coupons in a cart session
Example
[%active_coupons%]
[%param *body%]
<div class="alert alert-success">
<h4>Congratulations!</h4>
<p>The discount <strong>[@title@] ([@subtitle@])</strong> has been applied to your order.</p>
</div>
[%/param%]
[%/active_coupons%]
Usage
This will list all the active discount coupons that the customer has entered the coupon code for or have been automatically applied to the shopping cart.
Parameters
Name | Options | Description |
---|---|---|
*header |
HTML & b@se tags | Renders a single usable space above the body |
*body |
HTML & b@se tags | Runs an array for each option in the tag |
*footer |
HTML & b@se tags | Renders a single usable space below the body |
*ifempty , ifempty:'' |
HTML & b@se tags | If their are no active coupons, this block is printed in place of the header , body & footer |
Data Tags (body)
Name | Discount Field | Example | Description |
---|---|---|---|
[@code@] |
Discount key | SAVE20 | The coupon code that triggers the event |
[@count@] |
– | 0 | A counter which will start from 0 and count for each time the body parameter runs |
[@date_updated@] |
– | 2018-08-05 14:51:09 | Date the coupon was last updated in the control panel (YYYY-MM-DD HH:MM:SS) |
[@discount_active@] |
Active | y | Discount is currently active. n - no, y - yes |
[@discount_auto@] |
Automatically apply discount | y | Automatically apply when conditions are met. n - no, y - yes |
[@discount_dialog@] |
Pop-up | n | Display a popup dialog box when the discount is automatically applied. n - no, y - yes |
[@discount_end@] |
End date/time | 2018-08-31 22:59:00 | Date and time the coupon / discount ends (YYYY-MM-DD HH:MM:SS) |
[@discount_exclusive@] |
Can this discount be used with other discounts? | n | Discount is exclusive and can not be used with other offers. n - no, y - yes |
[@discount_id@] |
– | 23 | Unique ID for the discount |
[@discount_max@] |
Max discount allowed | 11.99 | Max monetary value the discount can be used for |
[@discount_once@] |
Usage policy | n | Whether the discount is single use or unlimited use. n - no, y - yes |
[@discount_private@] |
– | n | Whether the discount is a public or private discount. n - no, y - yes |
[@discount_start@] |
Start date/time | 2018-08-05 10:00:00 | Date the coupon / discount is valid (YYYY-MM-DD HH:MM:SS) |
[@subtitle@] |
Subtitle | Limited time only | The coupon program subtitle |
[@title@] |
Title | 20% Off Site-wide | The coupon program title |