Exchange Theme Templates: super-widget-checkout/loops/actions.php

From IThemes Codex
Revision as of 16:28, August 14, 2013 by Kopepasah (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This is the default template for the super-widget-checkout actions loop.

Contents

Theme Location

theme/exchange/super-widget-checkout/loops/actions.php

Action Hooks

Theme API

Default Code

<?php
/**
 * This is the default template for the 
 * super-widget-checkout actions loop.
 *
 * @since 1.1.0
 * @version 1.1.0
 * @package IT_Exchange
 * 
 * WARNING: Do not edit this file directly. To use
 * this template in a theme, copy over this file
 * to the exchange/super-widget-checkout/loops directory
 * located in your theme.
*/
?>

<?php
// Two actions or one?
$actions_count = ( ( it_exchange( 'coupons', 'accepting', array( 'type' => 'cart' ) ) || it_exchange( 'coupons', 'has-applied', array( 'type' => 'cart' ) ) ) && it_exchange_get_global( 'can_edit_purchase_quantity' ) ) || ( it_exchange_is_multi_item_cart_allowed() && it_exchange_get_cart_products_count() > 1 ) ? ' two-actions' : '';
?>

<?php do_action( 'it_exchange_super_widget_cart_before_actions_loop' ); ?>
<?php do_action( 'it_exchange_super_widget_cart_before_actions_wrap' ); ?>
<div class="cart-actions-wrapper <?php echo $actions_count; ?>">
	<?php if ( it_exchange_is_multi_item_cart_allowed() && it_exchange_get_cart_products_count() > 1 ) : ?>
		<?php foreach( it_exchange_get_template_part_elements( 'super-widget-checkout', 'multi-item-cart-actions', array( 'multi-item-cancel', 'multi-item-checkout' ) ) as $element ) : ?>
			<?php it_exchange_get_template_part( 'super-widget-checkout/elements/' . $element ); ?>
		<?php endforeach; ?>
	<?php else : ?>
		<?php foreach( it_exchange_get_template_part_elements( 'super-widget-checkout', 'single-item-cart-actions', array( 'single-item-update-coupons', 'single-item-update-quantity' ) ) as $element ) : ?>
			<?php it_exchange_get_template_part( 'super-widget-checkout/elements/' . $element ); ?>
		<?php endforeach; ?>
	<?php endif; ?>
</div>
<?php do_action( 'it_exchange_super_widget_cart_after_actions_wrap' ); ?>
<?php do_action( 'it_exchange_super_widget_cart_after_actions_loop' ); ?>

← Back to Exchange Theme Templates Page

Personal tools
Namespaces
Variants
Actions
iThemes Codex
Codex Navigation
Toolbox