Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php $_item = $this->getItem()?>
- <tr>
- <td class="a-center"><a href="<?php echo $this->getDeleteUrl() ?>"><img src="<?php echo $this->getSkinUrl('images/btn_trash.gif') ?>" alt="<?php echo $this->__('Remove item')?>" title="<?php echo $this->__('Remove item')?>" /></a></td>
- <td><a href="<?php echo $this->getProductUrl() ?>" class="product-image"><img src="<?php echo $this->getProductThumbnail()->resize(75); ?>" width="75" alt="<?php echo $this->htmlEscape($this->getProductName()) ?>" title="<?php echo $this->htmlEscape($this->getProductName()) ?>" /></a></td>
- <td>
- <h3 class="product-name"><a href="<?php echo $this->getProductUrl() ?>"><?php echo $this->getProductName() ?></a></h3>
- <?php if ($_options = $this->getOptionList()):?>
- <? /* Code Pasted from Inchoo.net starts here */?>
- <?php
- if($this->getProduct()->isConfigurable()){
- $_product = Mage::getModel('catalog/product')->load($this->getProduct()->getId());
- Mage::getBlockSingleton('catalog/product_view_type_configurable')->unsetData();
- $_configurable = Mage::getBlockSingleton('catalog/product_view_type_configurable')->setData('product', $_product);
- $_cdata = json_decode($_configurable->getJsonConfig());
- $_current = array();
- foreach((array)$this->getOptionList() as $_option) {
- $_current[$_option['label']]=$_option['value'];
- }
- foreach($_cdata->attributes as $attribute) {
- ?>
- <strong><?php echo $attribute->label; ?></strong>
- <select style="width:150px;" name="cart[<?php echo $_item->getId() ?>][option][< ?php echo $attribute->id ?>]">
- <?php foreach($attribute->options as $option) { ?>
- <option <?php echo ($_current[$attribute->label]==$option->label) ? ' selected' : '' ?> value="< ?php echo $option->id ?>"><?php echo $option->label ?> <?php echo $this->helper('checkout')->formatPrice($option->price+$_item->getProduct()->getPrice()) ?></option>
- <?php } ?>
- </select>
- <?php } } else { } ?> <!--UNSURE ABOUT THIS -->
- <? /* Code Pasted from Inchoo.net starts here */?>
- <!-- ORIGINAL CODE FROM THIS POINT FORWARD -->
- <dl class="item-options">
- <?php foreach ($_options as $_option) : ?>
- <?php $_formatedOptionValue = $this->getFormatedOptionValue($_option['value']) ?>
- <dt><?php echo $this->htmlEscape($_option['label']) ?></dt>
- <dd<?php if (isset($_formatedOptionValue['full_view'])): ?> class="truncated"<?php endif; ?>><?php echo $_formatedOptionValue['value'] ?>
- <?php if (isset($_formatedOptionValue['full_view'])): ?>
- <div class="truncated_full_value">
- <dl class="item-options">
- <dt><?php echo $this->htmlEscape($_option['label']) ?></dt>
- <dd><?php echo $_formatedOptionValue['full_view'] ?></dd>
- </dl>
- </div>
- <?php endif; ?>
- </dd>
- <?php endforeach; ?>
- </dl>
- <?php endif;?>
- <?php if ($messages = $this->getMessages()): ?>
- <?php foreach ($messages as $message): ?>
- <p class="item-msg <?php echo $message['type'] ?>">* <?php echo $message['text'] ?></p>
- <?php endforeach; ?>
- <?php endif; ?>
- </td>
- <?php if ($this->helper('wishlist')->isAllowInCart()) : ?>
- <td class="a-center">
- <input type="checkbox" value="1" name="cart[<?php echo $_item->getId() ?>][wishlist]" class="checkbox" />
- </td>
- <?php endif ?>
- <?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
- <td class="a-right">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <?php else: ?>
- <div class="cart-price">
- <?php endif; ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()+$_item->getWeeeTaxAppliedAmount()+$_item->getWeeeTaxDisposition()); ?>
- <?php else: ?>
- <?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()) ?>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->getApplied($_item)): ?>
- <div class="cart-tax-info" id="eunit-item-tax-details<?php echo $_item->getId(); ?>" style="display: none;">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><small><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></small></span><br />
- <?php endforeach; ?>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <span class="nobr"><?php echo Mage::helper('weee')->__('Total'); ?>:<br /> <?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()+$_item->getWeeeTaxAppliedAmount()+$_item->getWeeeTaxDisposition()); ?></span>
- </div>
- <?php endif; ?>
- <?php endif; ?>
- </td>
- <?php endif; ?>
- <?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
- <td class="a-right">
- <?php $_incl = $this->helper('checkout')->getPriceInclTax($_item); ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <?php else: ?>
- <div class="cart-price">
- <?php endif; ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php echo $this->helper('checkout')->formatPrice($_incl+$_item->getWeeeTaxAppliedAmount()); ?>
- <?php else: ?>
- <?php echo $this->helper('checkout')->formatPrice($_incl-$_item->getWeeeTaxDisposition()) ?>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->getApplied($_item)): ?>
- <div class="cart-tax-info" id="unit-item-tax-details<?php echo $_item->getId(); ?>" style="display: none;">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><small><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></small></span><br />
- <?php endforeach; ?>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <span class="nobr"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>:<br /> <?php echo $this->helper('checkout')->formatPrice($_incl+$_item->getWeeeTaxAppliedAmount()); ?></span>
- </div>
- <?php endif; ?>
- <?php endif; ?>
- </td>
- <?php endif; ?>
- <td class="a-center">
- <input name="cart[<?php echo $_item->getId() ?>][qty]" value="<?php echo $this->getQty() ?>" size="4" class="input-text qty" maxlength="8" />
- </td>
- <?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
- <td class="a-right">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <?php else: ?>
- <div class="cart-price">
- <?php endif; ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()+$_item->getWeeeTaxAppliedRowAmount()+$_item->getWeeeTaxRowDisposition()); ?>
- <?php else: ?>
- <?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()) ?>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->getApplied($_item)): ?>
- <div class="cart-tax-info" id="esubtotal-item-tax-details<?php echo $_item->getId(); ?>" style="display: none;">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><small><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></small></span><br />
- <?php endforeach; ?>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <span class="nobr"><?php echo Mage::helper('weee')->__('Total'); ?>:<br /> <?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()+$_item->getWeeeTaxAppliedRowAmount()+$_item->getWeeeTaxRowDisposition()); ?></span>
- </div>
- <?php endif; ?>
- <?php endif; ?>
- </td>
- <?php endif; ?>
- <?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
- <td class="a-right">
- <?php $_incl = $this->helper('checkout')->getSubtotalInclTax($_item); ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <?php else: ?>
- <div class="cart-price">
- <?php endif; ?>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php echo $this->helper('checkout')->formatPrice($_incl+$_item->getWeeeTaxAppliedRowAmount()); ?>
- <?php else: ?>
- <?php echo $this->helper('checkout')->formatPrice($_incl-$_item->getWeeeTaxRowDisposition()) ?>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->getApplied($_item)): ?>
- <div class="cart-tax-info" id="subtotal-item-tax-details<?php echo $_item->getId(); ?>" style="display: none;">
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><small><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></small></span><br />
- <?php endforeach; ?>
- <?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <small>
- <?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
- <span class="nobr"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></span><br />
- <?php endforeach; ?>
- </small>
- <?php endif; ?>
- </div>
- <?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
- <div class="cart-tax-total" onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
- <span class="nobr"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>:<br /> <?php echo $this->helper('checkout')->formatPrice($_incl+$_item->getWeeeTaxAppliedRowAmount()); ?></span>
- </div>
- <?php endif; ?>
- <?php endif; ?>
- </td>
- <?php endif; ?>
- </tr>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement