Guest User

price.phtml

a guest
Feb 25th, 2016
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.40 KB | None | 0 0
  1. <?php
  2. /**
  3. * Magento
  4. *
  5. * NOTICE OF LICENSE
  6. *
  7. * This source file is subject to the Academic Free Licenseeee(AFL 3.0)
  8. * that is bundled with this package in the file LICENSE_AFL.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * opensource.org/licenses/…
  11. * If you did not receive a copy of the license and are unable to
  12. * obtain it through the world-wide-web, please send an email
  13. * to license@magentocommerce.com so we can send you a copy immediately.
  14. *
  15. * DISCLAIMER
  16. *
  17. * Do not edit or add to this file if you wish to upgrade Magento to newer
  18. * versions in the future. If you wish to customize Magento for your
  19. * needs please refer to magentocommerce.com for more information.
  20. *
  21. * @category design
  22. * @package base_default
  23. * @copyright Copyright (c) 2014 Magento Inc. (magentocommerce.com)
  24. * @license opensource.org/licenses/… Academic Free License (AFL 3.0)
  25. */
  26. ?>
  27.  
  28. <?php
  29. /**
  30. * Template for displaying product price in different places (products grid, product view page etc)
  31. *
  32. * @see Mage_Catalog_Block_Product_Abstract
  33. */
  34. ?>
  35. <?php
  36. $_coreHelper = $this->helper('core');
  37. $_weeeHelper = $this->helper('weee');
  38. $_taxHelper = $this->helper('tax');
  39. /* @var $_coreHelper Mage_Core_Helper_Data */
  40. /* @var $_weeeHelper Mage_Weee_Helper_Data */
  41. /* @var $_taxHelper Mage_Tax_Helper_Data */
  42.  
  43. $_product = $this->getProduct();
  44. $_storeId = $_product->getStoreId();
  45. $_store = $_product->getStore();
  46. $_id = $_product->getId();
  47. $_weeeSeparator = '';
  48. $_simplePricesTax = ($_taxHelper->displayPriceIncludingTax() || $_taxHelper->displayBothPrices());
  49. $_minimalPriceValue = $_product->getMinimalPrice();
  50. $_minimalPriceValue = $_store->roundPrice($_store->convertPrice($_minimalPriceValue));
  51. $_minimalPrice = $_taxHelper->getPrice($_product, $_minimalPriceValue, $_simplePricesTax);
  52. $_convertedFinalPrice = $_store->roundPrice($_store->convertPrice($_product->getFinalPrice()));
  53. $_specialPriceStoreLabel = $this->getProductAttribute('special_price')->getStoreLabel();
  54. $helperSettings = Mage::helper('em0113settings');
  55. ?>
  56.  
  57. <?php if (!$_product->isGrouped()): ?>
  58. <?php $_weeeTaxAmount = $_weeeHelper->getAmountForDisplay($_product); ?>
  59. <?php $_weeeTaxAttributes = $_weeeHelper->getProductWeeeAttributesForRenderer($_product, null, null, null, true); ?>
  60. <?php $_weeeTaxAmountInclTaxes = $_weeeTaxAmount; ?>
  61. <?php if ($_weeeHelper->isTaxable()): ?>
  62. <?php $_weeeTaxAmountInclTaxes = $_weeeHelper->getAmountInclTaxes($_weeeTaxAttributes); ?>
  63. <?php endif; ?>
  64. <?php $_weeeTaxAmount = $_store->roundPrice($_store->convertPrice($_weeeTaxAmount)); ?>
  65. <?php $_weeeTaxAmountInclTaxes = $_store->roundPrice($_store->convertPrice($_weeeTaxAmountInclTaxes)); ?>
  66.  
  67. <div class="price-box">
  68. <?php $_convertedPrice = $_store->roundPrice($_store->convertPrice($_product->getPrice())); ?>
  69. <?php $_price = $_taxHelper->getPrice($_product, $_convertedPrice); ?>
  70. <?php $_regularPrice = $_taxHelper->getPrice($_product, $_convertedPrice, $_simplePricesTax); ?>
  71. <?php $_finalPrice = $_taxHelper->getPrice($_product, $_convertedFinalPrice) ?>
  72. <?php $_finalPriceInclTax = $_taxHelper->getPrice($_product, $_convertedFinalPrice, true) ?>
  73. <?php $_weeeDisplayType = $_weeeHelper->getPriceDisplayType(); ?>
  74. <?php if ($_finalPrice >= $_price): ?>
  75. <?php if ($_taxHelper->displayBothPrices()): ?>
  76. <?php if ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 0)): // including ?>
  77. <span class="price-excluding-tax">
  78. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  79. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  80. <?php echo $_coreHelper->formatPrice($_price + $_weeeTaxAmount, false) ?>
  81. <p class="mrp"><?php echo "MRP"; ?></p>
  82. </span>
  83. </span>
  84. <span class="price-including-tax">
  85. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  86. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  87. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  88. <p class="mrp"><?php echo "MRP"; ?></p>
  89. </span>
  90. </span>
  91. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 1)): // incl. + weee ?>
  92. <span class="price-excluding-tax">
  93. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  94. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  95. <?php echo $_coreHelper->formatPrice($_price + $_weeeTaxAmount, false) ?>
  96. <p class="mrp"><?php echo "MRP"; ?></p>
  97. </span>
  98. </span>
  99. <span class="weee">(
  100. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  101. <?php echo $_weeeSeparator; ?>
  102. <?php echo $_weeeTaxAttribute->getName(); ?>: <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount(), true, true); ?>
  103. <?php $_weeeSeparator = ' + '; ?>
  104. <?php endforeach; ?>
  105. )</span>
  106. <span class="price-including-tax">
  107. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  108. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  109. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  110. <p class="mrp"><?php echo "MRP"; ?></p>
  111. </span>
  112. </span>
  113. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 4)): // incl. + weee ?>
  114. <span class="price-excluding-tax">
  115. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  116. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  117. <?php echo $_coreHelper->formatPrice($_price + $_weeeTaxAmount, false) ?>
  118. <p class="mrp"><?php echo "MRP"; ?></p>
  119. </span>
  120. </span>
  121. <span class="price-including-tax">
  122. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  123. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  124. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  125. <p class="mrp"><?php echo "MRP"; ?></p>
  126. </span>
  127. <span class="weee">(
  128. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  129. <?php echo $_weeeSeparator; ?>
  130. <?php echo $_weeeTaxAttribute->getName(); ?>: <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + $_weeeTaxAttribute->getTaxAmount(), true, true); ?>
  131. <?php $_weeeSeparator = ' + '; ?>
  132. <?php endforeach; ?>
  133. )</span>
  134. </span>
  135. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 2)): // excl. + weee + final ?>
  136. <span class="price-excluding-tax">
  137. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  138. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  139. <?php echo $_coreHelper->formatPrice($_price, false) ?>
  140. <p class="mrp"><?php echo "MRP"; ?></p>
  141. </span>
  142. </span>
  143. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  144. <span class="weee">
  145. <?php echo $_weeeTaxAttribute->getName(); ?>
  146. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + $_weeeTaxAttribute->getTaxAmount(), true, true); ?>
  147. <p class="mrp"><?php echo "MRP"; ?></p>
  148. </span>
  149. <?php endforeach; ?>
  150. <span class="price-including-tax">
  151. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  152. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  153. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  154. <p class="mrp"><?php echo "MRP"; ?></p>
  155. </span>
  156. </span>
  157. <?php else: ?>
  158. <span class="price-excluding-tax">
  159. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  160. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  161. <?php if ($_finalPrice == $_price): ?>
  162. <?php echo $_coreHelper->formatPrice($_price, false) ?>
  163. <p class="mrp"><?php echo "MRP"; ?></p>
  164. <?php else: ?>
  165. <?php echo $_coreHelper->formatPrice($_finalPrice, false) ?>
  166. <p class="mrp"><?php echo "MRP"; ?></p>
  167. <?php endif; ?>
  168. </span>
  169. </span>
  170. <span class="price-including-tax">
  171. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  172. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  173. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax, false) ?>
  174. <p class="mrp"><?php echo "MRP"; ?></p>
  175. </span>
  176. </span>
  177. <?php endif; ?>
  178. <?php else: ?>
  179. <?php if ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, array(0, 1))): // including ?>
  180. <?php $weeeAmountToDisplay = $_taxHelper->displayPriceIncludingTax() ? $_weeeTaxAmountInclTaxes : $_weeeTaxAmount ?>
  181. <span class="regular-price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  182. <?php echo $_coreHelper->currency($_price + $weeeAmountToDisplay, true, true) ?>
  183. <p class="mrp"><?php echo "MRP"; ?></p>
  184. </span>
  185.  
  186. <?php if ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 1)): // show description ?>
  187. <span class="weee">(
  188. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  189. <?php echo $_weeeSeparator; ?>
  190. <?php echo $_weeeTaxAttribute->getName(); ?>
  191. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + ($_taxHelper->displayPriceIncludingTax() ? $_weeeTaxAttribute->getTaxAmount() : 0), true, true); ?>
  192. <?php $_weeeSeparator = ' + '; ?>
  193. <?php endforeach; ?>
  194. )</span>
  195. <?php endif; ?>
  196. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 4)): // incl. + weee ?>
  197. <span class="regular-price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  198. <?php echo $_coreHelper->formatPrice($_price + $_weeeTaxAmount, true) ?>
  199. <p class="mrp"><?php echo "MRP"; ?></p>
  200. </span>
  201. <span class="weee">(
  202. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  203. <?php echo $_weeeSeparator; ?>
  204. <?php echo $_weeeTaxAttribute->getName(); ?>: <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + $_weeeTaxAttribute->getTaxAmount(), true, true); ?>
  205. <?php $_weeeSeparator = ' + '; ?>
  206. <?php endforeach; ?>
  207. )</span>
  208. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 2)): // excl. + weee + final ?>
  209. <span class="regular-price"><?php echo $_coreHelper->formatPrice($_price, true) ?></span><br/>
  210. <?php $weeeAmountToDisplay = $_taxHelper->displayPriceIncludingTax() ? $_weeeTaxAmountInclTaxes : $_weeeTaxAmount ?>
  211. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  212. <span class="weee">
  213. <?php echo $_weeeTaxAttribute->getName(); ?>
  214. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + ($_taxHelper->displayPriceIncludingTax() ? $_weeeTaxAttribute->getTaxAmount() : 0), true, true); ?>
  215. <p class="mrp"><?php echo "MRP"; ?></p>
  216. </span>
  217. <?php endforeach; ?>
  218. <span class="regular-price"
  219. id="product-price-weee-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  220. <?php echo $_coreHelper->currency($_price + $weeeAmountToDisplay, true, true) ?>
  221. <p class="mrp"><?php echo "MRP"; ?></p>
  222. </span>
  223. <?php else: ?>
  224. <span class="regular-price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  225. <?php if ($_finalPrice == $_price): ?>
  226. <?php echo $_coreHelper->formatPrice($_price, true) ?><p class="mrp"><?php echo "MRP"; ?></p>
  227. <?php else: ?>
  228. <?php echo $_coreHelper->formatPrice($_finalPrice, true) ?><p class="mrp"><?php echo "MRP"; ?></p>
  229. <?php endif; ?>
  230. </span>
  231. <?php endif; ?>
  232. <?php endif; ?>
  233. <?php else: /* if ($_finalPrice == $_price): */ ?>
  234. <?php $_originalWeeeTaxAmount = $_weeeHelper->getOriginalAmount($_product); ?>
  235. <?php $_originalWeeeTaxAmount = $_store->roundPrice($_store->convertPrice($_originalWeeeTaxAmount)) ?>
  236.  
  237. <?php if ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 0)): // including ?>
  238. <p class="old-price">
  239. <span class="price-label"><?php echo $this->__('Regular Price:') ?></span>
  240. <span class="price" id="old-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  241. <?php echo $_coreHelper->formatPrice($_regularPrice + $_originalWeeeTaxAmount, false) ?><p class="mrp"><?php echo "MRP"; ?></p>
  242. </span>
  243. </p>
  244.  
  245. <?php if ($_taxHelper->displayBothPrices()): ?>
  246. <p class="special-price">
  247. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  248. <span class="price-excluding-tax">
  249. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  250. <span class="price"
  251. id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  252. <?php echo $_coreHelper->formatPrice($_finalPrice + $_weeeTaxAmount, false) ?><p class="mrp"><?php echo "MRP"; ?></p>
  253. </span>
  254. </span>
  255. <span class="price-including-tax">
  256. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  257. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  258. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?><p class="mrp"><?php echo "MRP"; ?></p>
  259. </span>
  260. </span>
  261. </p>
  262. <?php else: ?>
  263. <p class="special-price">
  264. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  265. <span class="price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  266. <?php echo $_coreHelper->formatPrice($_finalPrice + $_weeeTaxAmountInclTaxes, false) ?>
  267. </span>
  268. </p>
  269. <?php endif; ?>
  270.  
  271. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 1)): // incl. + weee ?>
  272. <p class="old-price">
  273. <span class="price-label"><?php echo $this->__('Regular Price:') ?></span>
  274. <span class="price" id="old-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  275. <?php echo $_coreHelper->formatPrice($_regularPrice + $_originalWeeeTaxAmount, false) ?>
  276. </span>
  277. </p>
  278.  
  279. <p class="special-price">
  280. <?php if ($_taxHelper->displayBothPrices()): ?>
  281. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  282. <span class="price-excluding-tax">
  283. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  284. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  285. <?php echo $_coreHelper->formatPrice($_finalPrice + $_weeeTaxAmount, false) ?>
  286. </span>
  287. </span>
  288. <span class="weee">(
  289. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  290. <?php echo $_weeeSeparator; ?>
  291. <?php echo $_weeeTaxAttribute->getName(); ?>
  292. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount(), true, true); ?>
  293. <?php $_weeeSeparator = ' + '; ?>
  294. <?php endforeach; ?>
  295. )</span>
  296. <span class="price-including-tax">
  297. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  298. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  299. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  300. </span>
  301. </span>
  302. <?php else: ?>
  303. <p class="special-price">
  304. <span class="price-label"><?php echo $this->__('Special Price:') ?></span>
  305. <span class="price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>>
  306. <?php echo $_coreHelper->formatPrice($_finalPrice + $_weeeTaxAmountInclTaxes, false) ?>
  307. </span>
  308. </p>
  309. <span class="weee">(
  310. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  311. <?php echo $_weeeSeparator; ?>
  312. <?php echo $_weeeTaxAttribute->getName(); ?>
  313. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount(), true, true); ?>
  314. <?php $_weeeSeparator = ' + '; ?>
  315. <?php endforeach; ?>
  316. )</span>
  317. <?php endif; ?>
  318. </p>
  319. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 4)): // incl. + weee ?>
  320. <p class="old-price">
  321. <span class="price-label"><?php echo $this->__('Regular Price:') ?></span>
  322. <span class="price" id="old-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  323. <?php echo $_coreHelper->formatPrice($_regularPrice + $_originalWeeeTaxAmount, false) ?>
  324. </span>
  325. </p>
  326.  
  327. <p class="special-price">
  328. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  329. <span class="price-excluding-tax">
  330. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  331. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  332. <?php echo $_coreHelper->formatPrice($_finalPrice + $_weeeTaxAmount, false) ?>
  333. </span>
  334. </span>
  335. <span class="weee">(
  336. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  337. <?php echo $_weeeSeparator; ?>
  338. <?php echo $_weeeTaxAttribute->getName(); ?>: <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount() + $_weeeTaxAttribute->getTaxAmount(), true, true); ?>
  339. <?php $_weeeSeparator = ' + '; ?>
  340. <?php endforeach; ?>
  341. )</span>
  342. <span class="price-including-tax">
  343. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  344. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  345. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  346. </span>
  347. </span>
  348. </p>
  349. <?php elseif ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, 2)): // excl. + weee + final ?>
  350. <p class="old-price">
  351. <span class="price-label"><?php echo $this->__('Regular Price:') ?></span>
  352. <span class="price" id="old-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?><?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>">
  353. <?php echo $_coreHelper->formatPrice($_regularPrice, false) ?>
  354.  
  355.  
  356. </span>
  357. </p>
  358.  
  359. <p class="special-price">
  360. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  361. <span class="price-excluding-tax">
  362. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  363. <span class="price" id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  364. <?php echo $_coreHelper->formatPrice($_finalPrice, false) ?>
  365. </span>
  366. </span>
  367. <?php foreach ($_weeeTaxAttributes as $_weeeTaxAttribute): ?>
  368. <span class="weee">
  369. <?php echo $_weeeTaxAttribute->getName(); ?>
  370. : <?php echo $_coreHelper->currency($_weeeTaxAttribute->getAmount(), true, true); ?>
  371. </span>
  372. <?php endforeach; ?>
  373. <span class="price-including-tax">
  374. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  375. <span class="price" id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  376. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax + $_weeeTaxAmountInclTaxes, false) ?>
  377. </span>
  378. </span>
  379. </p>
  380. <?php else: // excl. ?>
  381. <p class="old-price"><?php echo "MRP: ";?>
  382. <span class="price-label"><?php echo $this->__('Regular Price:') ?></span>
  383. <span class="price" id="old-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="price"<?php endif;?>>
  384.  
  385. <?php echo $_coreHelper->formatPrice($_regularPrice, false) ?>
  386. </span>
  387. </p>
  388.  
  389. <?php if ($_taxHelper->displayBothPrices()): ?>
  390. <p class="special-price">
  391. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  392. <span class="price-excluding-tax">
  393. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  394. <span class="price"
  395. id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  396. <?php echo $_coreHelper->formatPrice($_finalPrice, false) ?>
  397. </span>
  398. </span>
  399. <span class="price-including-tax">
  400. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  401. <span class="price"
  402. id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  403. <?php echo $_coreHelper->formatPrice($_finalPriceInclTax, false) ?>
  404. </span>
  405. </span>
  406. </p>
  407. <?php else: ?>
  408. <p class="special-price">
  409.  
  410.  
  411.  
  412. <span class="price-label"><?php echo $_specialPriceStoreLabel ?></span>
  413. <span class="price" id="product-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  414. <?php echo $_coreHelper->formatPrice($_finalPrice, false) ?>
  415.  
  416. <!-- ship price
  417. <?php $deliveryPrice = $_product->getData("mp_local_shipping_charge") ?>
  418. <?php if($deliveryPrice === "0"): ?>
  419. <p class="sell_price"><?php echo "Selling Price (Free Delivery )"; ?> </p>
  420. <?php elseif(empty($deliveryPrice)): ?>
  421. <p class="sell_price"><?php echo "Selling Price + Rs 50 Delivery "; ?> </p>
  422. <?php else: ?>
  423. <p class="sell_price"><?php echo "Selling Price"; ?>
  424. <?php echo "+ Rs " . $_product->getData("mp_local_shipping_charge") . " Delivery "; ?>
  425. <?php endif; ?>
  426. </p>
  427.  
  428. shipping price -->
  429.  
  430. </span>
  431.  
  432.  
  433. <?php endif; ?>
  434. <?php endif; ?>
  435. <div class="You_savee">
  436. <?php // Discount percents output start ?>
  437. <?php if($_finalPrice < $_price): ?>
  438. <?php $_savePercent = 100 - round(($_finalPrice / $_price)*100); ?>
  439. <p class="special-price yousave">
  440. <span class="label yousave_label"><?php echo $this->__('You Save:') ?></span>
  441. <span class="you_save_price">
  442. <?php echo $_savePercent."%" ?>
  443. </span>
  444. </p>
  445. <?php endif; ?>
  446. </div>
  447. <?php // Discount percent output end ?>
  448. <?php endif; /* if ($_finalPrice == $_price): */ ?>
  449.  
  450. <?php if ($this->getDisplayMinimalPrice() && $_minimalPriceValue && $_minimalPriceValue < $_convertedFinalPrice): ?>
  451.  
  452. <?php $_minimalPriceDisplayValue = $_minimalPrice; ?>
  453. <?php if ($_weeeTaxAmount && $_weeeHelper->typeOfDisplay($_product, array(0, 1, 4))): ?>
  454. <?php $_minimalPriceDisplayValue = $_minimalPrice + $_weeeTaxAmount; ?>
  455. <?php endif; ?>
  456.  
  457. <?php if ($this->getUseLinkForAsLowAs()): ?>
  458. <a href="<?php echo $_product->getProductUrl(); ?>" class="minimal-price-link">
  459. <?php else: ?>
  460. <span class="minimal-price-link">
  461. <?php endif ?>
  462. <span class="label"><?php echo $this->__('As low as:') ?></span>
  463. <span class="price" id="product-minimal-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  464. <?php echo $_coreHelper->formatPrice($_minimalPriceDisplayValue, false) ?>
  465. </span>
  466. <?php if ($this->getUseLinkForAsLowAs()): ?>
  467. </a>
  468. <?php else: ?>
  469. </span>
  470. <?php endif ?>
  471. <?php endif; /* if ($this->getDisplayMinimalPrice() && $_minimalPrice && $_minimalPrice < $_finalPrice): */ ?>
  472. </div>
  473.  
  474. <?php else: /* if (!$_product->isGrouped()): */ ?>
  475. <?php
  476. $showMinPrice = $this->getDisplayMinimalPrice();
  477. if ($showMinPrice && $_minimalPriceValue) {
  478. $_exclTax = $_taxHelper->getPrice($_product, $_minimalPriceValue);
  479. $_inclTax = $_taxHelper->getPrice($_product, $_minimalPriceValue, true);
  480. $price = $showMinPrice ? $_minimalPriceValue : 0;
  481. } else {
  482. $price = $_convertedFinalPrice;
  483. $_exclTax = $_taxHelper->getPrice($_product, $price);
  484. $_inclTax = $_taxHelper->getPrice($_product, $price, true);
  485. }
  486. ?>
  487. <?php if ($price): ?>
  488. <div class="price-box">
  489. <p<?php if ($showMinPrice): ?> class="minimal-price"<?php endif ?>>
  490. <?php if ($showMinPrice): ?>
  491. <span class="price-label"><?php echo $this->__('Starting at:') ?></span>
  492. <?php endif ?>
  493. <?php if ($_taxHelper->displayBothPrices()): ?>
  494. <span class="price-excluding-tax">
  495. <span class="label"><?php echo $this->helper('tax')->__('Excl. Tax:') ?></span>
  496. <span class="price"
  497. id="price-excluding-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  498. <?php echo $_coreHelper->formatPrice($_exclTax, false) ?>
  499. </span>
  500.  
  501. </span>
  502. </span>
  503. <span class="price-including-tax">
  504. <span class="label"><?php echo $this->helper('tax')->__('Incl. Tax:') ?></span>
  505. <span class="price"
  506. id="price-including-tax-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="highPrice"<?php endif;?>>
  507. <?php echo $_coreHelper->formatPrice($_inclTax, false) ?>
  508. </span>
  509. </span>
  510. <?php else: ?>
  511. <?php
  512. $_showPrice = $_inclTax;
  513. if (!$_taxHelper->displayPriceIncludingTax()) {
  514. $_showPrice = $_exclTax;
  515. }
  516. ?>
  517. <span class="price" id="product-minimal-price-<?php echo $_id ?><?php echo $this->getIdSuffix() ?>"<?php if($helperSettings->isShowOfferPrice($_product)):?> itemprop="lowPrice"<?php endif;?>>
  518. <?php echo $_coreHelper->formatPrice($_showPrice, false) ?>
  519. </span>
  520. <?php endif; ?>
  521. </p>
  522. </div>
  523. <?php endif; /* if ($this->getDisplayMinimalPrice() && $_minimalPrice): */ ?>
  524. <?php endif; /* if (!$_product->isGrouped()): */ ?>
Add Comment
Please, Sign In to add comment