<?php
/**
 * Avalanche for Magento 1.8+
 * Designed by Fast Division (http://fastdivision.com)
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to the EULA
 * that is bundled with this package in the file license.txt.
 * It is also available through the world-wide-web at this URL:
 * http://fastdivision.com/legal/license.txt
 *
 * @author     Fast Division
 * @version    1.5.0
 * @copyright  Copyright 2013 Fast Division
 * @license    http://fastdivision.com/legal/license.txt
 */
?>
<?php echo $this->getChildHtml('items_before'); ?>

<div id="checkout-review-table-wrapper">
    <table id="checkout-review-table">
        <thead>
            <tr>
				<th class="a-center" style="width: 81px">
                    <?php echo $this->__('Qty.') ?>
                </th>
                <th colspan="2">
                    <?php echo $this->__('Items In Your Cart') ?>
                </th>
                <th class="a-center" style="width: 104px">
                    <?php echo $this->__('Each') ?>
                </th>
				<th class="a-center" style="width: 104px">
					<?php echo $this->__('Total') ?>
				</th>
            </tr>
        </thead>
        <tbody>
        <?php foreach($this->getItems() as $_item): ?>
            <?php echo $this->getItemHtml($_item)?>
        <?php endforeach ?>
        </tbody>
    </table>
</div>

<?php echo $this->getChildHtml('items_after'); ?>

<div id="checkout-complete">
    <?php echo $this->getChildHtml('agreements') ?>
    <div class="buttons-set" id="review-buttons-container">
		<button type="submit" title="<?php echo $this->__('Complete Order') ?>" class="action-button action-button-medium btn-checkout" onclick="review.save();"><span><?php echo $this->__('Complete Order') ?></span></button>
        <span class="please-wait" id="review-please-wait" style="display:none;">
            <img src="<?php echo $this->getSkinUrl('images/opc-ajax-loader.gif') ?>" alt="<?php echo $this->__('Submitting order information...') ?>" title="<?php echo $this->__('Submitting order information...') ?>" class="v-middle" /> <?php echo $this->__('Submitting order information...') ?>
        </span>
    </div>
    <script type="text/javascript">
    //<![CDATA[
        review = new Review('<?php echo $this->getUrl('checkout/onepage/saveOrder', array('form_key' => Mage::getSingleton('core/session')->getFormKey())) ?>', '<?php echo $this->getUrl('checkout/onepage/success') ?>', $('checkout-agreements'));
    //]]>
    </script>
</div>
