PageRenderTime 80ms CodeModel.GetById 32ms RepoModel.GetById 0ms app.codeStats 0ms

/tools/smarty/compile/0bcc4f733e3111ea5f31239e33cebce82446c81b.file.product.tpl.php

http://marocmall.googlecode.com/
PHP | 886 lines | 831 code | 45 blank | 10 comment | 133 complexity | 282a256a588947dedb2ce8142a0a89b3 MD5 | raw file
Possible License(s): LGPL-2.1

Large files files are truncated, but you can click here to view the full file

  1. <?php /* Smarty version Smarty-3.0.7, created on 2011-12-27 11:35:24
  2. compiled from "C:\D\prestashoplf\prestashop/themes/prestashop/product.tpl" */ ?>
  3. <?php /*%%SmartyHeaderCode:246174ef9ad7c57aab3-89333898%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
  4. $_smarty_tpl->decodeProperties(array (
  5. 'file_dependency' =>
  6. array (
  7. '0bcc4f733e3111ea5f31239e33cebce82446c81b' =>
  8. array (
  9. 0 => 'C:\\D\\prestashoplf\\prestashop/themes/prestashop/product.tpl',
  10. 1 => 1308061904,
  11. 2 => 'file',
  12. ),
  13. ),
  14. 'nocache_hash' => '246174ef9ad7c57aab3-89333898',
  15. 'function' =>
  16. array (
  17. ),
  18. 'has_nocache_code' => false,
  19. )); /*/%%SmartyHeaderCode%%*/?>
  20. <?php if (!is_callable('smarty_modifier_escape')) include 'C:\D\prestashoplf\prestashop\tools\smarty\plugins\modifier.escape.php';
  21. if (!is_callable('smarty_modifier_date_format')) include 'C:\D\prestashoplf\prestashop\tools\smarty\plugins\modifier.date_format.php';
  22. if (!is_callable('smarty_function_math')) include 'C:\D\prestashoplf\prestashop\tools\smarty\plugins\function.math.php';
  23. if (!is_callable('smarty_function_counter')) include 'C:\D\prestashoplf\prestashop\tools\smarty\plugins\function.counter.php';
  24. ?>
  25. <?php $_template = new Smarty_Internal_Template(($_smarty_tpl->getVariable('tpl_dir')->value)."./errors.tpl", $_smarty_tpl->smarty, $_smarty_tpl, $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null);
  26. echo $_template->getRenderedTemplate();?><?php unset($_template);?>
  27. <?php if (count($_smarty_tpl->getVariable('errors')->value)==0){?>
  28. <script type="text/javascript">
  29. // <![CDATA[
  30. // PrestaShop internal settings
  31. var currencySign = '<?php echo html_entity_decode($_smarty_tpl->getVariable('currencySign')->value,2,"UTF-8");?>
  32. ';
  33. var currencyRate = '<?php echo floatval($_smarty_tpl->getVariable('currencyRate')->value);?>
  34. ';
  35. var currencyFormat = '<?php echo intval($_smarty_tpl->getVariable('currencyFormat')->value);?>
  36. ';
  37. var currencyBlank = '<?php echo intval($_smarty_tpl->getVariable('currencyBlank')->value);?>
  38. ';
  39. var taxRate = <?php echo floatval($_smarty_tpl->getVariable('tax_rate')->value);?>
  40. ;
  41. var jqZoomEnabled = <?php if ($_smarty_tpl->getVariable('jqZoomEnabled')->value){?>true<?php }else{ ?>false<?php }?>;
  42. //JS Hook
  43. var oosHookJsCodeFunctions = new Array();
  44. // Parameters
  45. var id_product = '<?php echo intval($_smarty_tpl->getVariable('product')->value->id);?>
  46. ';
  47. var productHasAttributes = <?php if (isset($_smarty_tpl->getVariable('groups',null,true,false)->value)){?>true<?php }else{ ?>false<?php }?>;
  48. var quantitiesDisplayAllowed = <?php if ($_smarty_tpl->getVariable('display_qties')->value==1){?>true<?php }else{ ?>false<?php }?>;
  49. var quantityAvailable = <?php if ($_smarty_tpl->getVariable('display_qties')->value==1&&$_smarty_tpl->getVariable('product')->value->quantity){?><?php echo $_smarty_tpl->getVariable('product')->value->quantity;?>
  50. <?php }else{ ?>0<?php }?>;
  51. var allowBuyWhenOutOfStock = <?php if ($_smarty_tpl->getVariable('allow_oosp')->value==1){?>true<?php }else{ ?>false<?php }?>;
  52. var availableNowValue = '<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->available_now,'quotes','UTF-8');?>
  53. ';
  54. var availableLaterValue = '<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->available_later,'quotes','UTF-8');?>
  55. ';
  56. var productPriceTaxExcluded = <?php echo (($tmp = @$_smarty_tpl->getVariable('product')->value->getPriceWithoutReduct(true))===null||$tmp==='' ? 'null' : $tmp);?>
  57. - <?php echo $_smarty_tpl->getVariable('product')->value->ecotax;?>
  58. ;
  59. var reduction_percent = <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction']&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction_type']=='percentage'){?><?php echo $_smarty_tpl->getVariable('product')->value->specificPrice['reduction']*100;?>
  60. <?php }else{ ?>0<?php }?>;
  61. var reduction_price = <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction']&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction_type']=='amount'){?><?php echo $_smarty_tpl->getVariable('product')->value->specificPrice['reduction'];?>
  62. <?php }else{ ?>0<?php }?>;
  63. var specific_price = <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['price']){?><?php echo $_smarty_tpl->getVariable('product')->value->specificPrice['price'];?>
  64. <?php }else{ ?>0<?php }?>;
  65. var specific_currency = <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['id_currency']){?>true<?php }else{ ?>false<?php }?>;
  66. var group_reduction = '<?php echo $_smarty_tpl->getVariable('group_reduction')->value;?>
  67. ';
  68. var default_eco_tax = <?php echo $_smarty_tpl->getVariable('product')->value->ecotax;?>
  69. ;
  70. var ecotaxTax_rate = <?php echo $_smarty_tpl->getVariable('ecotaxTax_rate')->value;?>
  71. ;
  72. var currentDate = '<?php echo smarty_modifier_date_format(time(),'%Y-%m-%d %H:%M:%S');?>
  73. ';
  74. var maxQuantityToAllowDisplayOfLastQuantityMessage = <?php echo $_smarty_tpl->getVariable('last_qties')->value;?>
  75. ;
  76. var noTaxForThisProduct = <?php if ($_smarty_tpl->getVariable('no_tax')->value==1){?>true<?php }else{ ?>false<?php }?>;
  77. var displayPrice = <?php echo $_smarty_tpl->getVariable('priceDisplay')->value;?>
  78. ;
  79. var productReference = '<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->reference,'htmlall','UTF-8');?>
  80. ';
  81. var productAvailableForOrder = <?php if ((isset($_smarty_tpl->getVariable('restricted_country_mode',null,true,false)->value)&&$_smarty_tpl->getVariable('restricted_country_mode')->value)||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?>'0'<?php }else{ ?>'<?php echo $_smarty_tpl->getVariable('product')->value->available_for_order;?>
  82. '<?php }?>;
  83. var productShowPrice = '<?php if (!$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?><?php echo $_smarty_tpl->getVariable('product')->value->show_price;?>
  84. <?php }else{ ?>0<?php }?>';
  85. var productUnitPriceRatio = '<?php echo $_smarty_tpl->getVariable('product')->value->unit_price_ratio;?>
  86. ';
  87. var idDefaultImage = <?php if (isset($_smarty_tpl->getVariable('cover',null,true,false)->value['id_image_only'])){?><?php echo $_smarty_tpl->getVariable('cover')->value['id_image_only'];?>
  88. <?php }else{ ?>0<?php }?>;
  89. // Customizable field
  90. var img_ps_dir = '<?php echo $_smarty_tpl->getVariable('img_ps_dir')->value;?>
  91. ';
  92. var customizationFields = new Array();
  93. <?php $_smarty_tpl->tpl_vars['imgIndex'] = new Smarty_variable(0, null, null);?>
  94. <?php $_smarty_tpl->tpl_vars['textFieldIndex'] = new Smarty_variable(0, null, null);?>
  95. <?php $_smarty_tpl->tpl_vars['field'] = new Smarty_Variable;
  96. $_from = $_smarty_tpl->getVariable('customizationFields')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  97. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['customizationFields']['index']=-1;
  98. if ($_smarty_tpl->_count($_from) > 0){
  99. foreach ($_from as $_smarty_tpl->tpl_vars['field']->key => $_smarty_tpl->tpl_vars['field']->value){
  100. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['customizationFields']['index']++;
  101. ?>
  102. <?php $_smarty_tpl->tpl_vars["key"] = new Smarty_variable("pictures_".($_smarty_tpl->getVariable('product')->value->id)."_".($_smarty_tpl->tpl_vars['field']->value['id_customization_field']), null, null);?>
  103. customizationFields[<?php echo intval($_smarty_tpl->getVariable('smarty')->value['foreach']['customizationFields']['index']);?>
  104. ] = new Array();
  105. customizationFields[<?php echo intval($_smarty_tpl->getVariable('smarty')->value['foreach']['customizationFields']['index']);?>
  106. ][0] = '<?php if (intval($_smarty_tpl->tpl_vars['field']->value['type'])==0){?>img<?php echo $_smarty_tpl->getVariable('imgIndex')->value++;?>
  107. <?php }else{ ?>textField<?php echo $_smarty_tpl->getVariable('textFieldIndex')->value++;?>
  108. <?php }?>';
  109. customizationFields[<?php echo intval($_smarty_tpl->getVariable('smarty')->value['foreach']['customizationFields']['index']);?>
  110. ][1] = <?php if (intval($_smarty_tpl->tpl_vars['field']->value['type'])==0&&isset($_smarty_tpl->getVariable('pictures',null,true,false)->value[$_smarty_tpl->getVariable('key',null,true,false)->value])&&$_smarty_tpl->getVariable('pictures')->value[$_smarty_tpl->getVariable('key')->value]){?>2<?php }else{ ?><?php echo intval($_smarty_tpl->tpl_vars['field']->value['required']);?>
  111. <?php }?>;
  112. <?php }} ?>
  113. // Images
  114. var img_prod_dir = '<?php echo $_smarty_tpl->getVariable('img_prod_dir')->value;?>
  115. ';
  116. var combinationImages = new Array();
  117. <?php if (isset($_smarty_tpl->getVariable('combinationImages',null,true,false)->value)){?>
  118. <?php $_smarty_tpl->tpl_vars['combination'] = new Smarty_Variable;
  119. $_smarty_tpl->tpl_vars['combinationId'] = new Smarty_Variable;
  120. $_from = $_smarty_tpl->getVariable('combinationImages')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  121. if ($_smarty_tpl->_count($_from) > 0){
  122. foreach ($_from as $_smarty_tpl->tpl_vars['combination']->key => $_smarty_tpl->tpl_vars['combination']->value){
  123. $_smarty_tpl->tpl_vars['combinationId']->value = $_smarty_tpl->tpl_vars['combination']->key;
  124. ?>
  125. combinationImages[<?php echo $_smarty_tpl->tpl_vars['combinationId']->value;?>
  126. ] = new Array();
  127. <?php $_smarty_tpl->tpl_vars['image'] = new Smarty_Variable;
  128. $_from = $_smarty_tpl->tpl_vars['combination']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  129. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['f_combinationImage']['index']=-1;
  130. if ($_smarty_tpl->_count($_from) > 0){
  131. foreach ($_from as $_smarty_tpl->tpl_vars['image']->key => $_smarty_tpl->tpl_vars['image']->value){
  132. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['f_combinationImage']['index']++;
  133. ?>
  134. combinationImages[<?php echo $_smarty_tpl->tpl_vars['combinationId']->value;?>
  135. ][<?php echo $_smarty_tpl->getVariable('smarty')->value['foreach']['f_combinationImage']['index'];?>
  136. ] = <?php echo intval($_smarty_tpl->tpl_vars['image']->value['id_image']);?>
  137. ;
  138. <?php }} ?>
  139. <?php }} ?>
  140. <?php }?>
  141. combinationImages[0] = new Array();
  142. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)){?>
  143. <?php $_smarty_tpl->tpl_vars['image'] = new Smarty_Variable;
  144. $_from = $_smarty_tpl->getVariable('images')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  145. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['f_defaultImages']['index']=-1;
  146. if ($_smarty_tpl->_count($_from) > 0){
  147. foreach ($_from as $_smarty_tpl->tpl_vars['image']->key => $_smarty_tpl->tpl_vars['image']->value){
  148. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['f_defaultImages']['index']++;
  149. ?>
  150. combinationImages[0][<?php echo $_smarty_tpl->getVariable('smarty')->value['foreach']['f_defaultImages']['index'];?>
  151. ] = <?php echo $_smarty_tpl->tpl_vars['image']->value['id_image'];?>
  152. ;
  153. <?php }} ?>
  154. <?php }?>
  155. // Translations
  156. var doesntExist = '<?php echo smartyTranslate(array('s'=>'The product does not exist in this model. Please choose another.','js'=>1),$_smarty_tpl);?>
  157. ';
  158. var doesntExistNoMore = '<?php echo smartyTranslate(array('s'=>'This product is no longer in stock','js'=>1),$_smarty_tpl);?>
  159. ';
  160. var doesntExistNoMoreBut = '<?php echo smartyTranslate(array('s'=>'with those attributes but is available with others','js'=>1),$_smarty_tpl);?>
  161. ';
  162. var uploading_in_progress = '<?php echo smartyTranslate(array('s'=>'Uploading in progress, please wait...','js'=>1),$_smarty_tpl);?>
  163. ';
  164. var fieldRequired = '<?php echo smartyTranslate(array('s'=>'Please fill in all required fields, then save the customization.','js'=>1),$_smarty_tpl);?>
  165. ';
  166. <?php if (isset($_smarty_tpl->getVariable('groups',null,true,false)->value)){?>
  167. // Combinations
  168. <?php $_smarty_tpl->tpl_vars['combination'] = new Smarty_Variable;
  169. $_smarty_tpl->tpl_vars['idCombination'] = new Smarty_Variable;
  170. $_from = $_smarty_tpl->getVariable('combinations')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  171. if ($_smarty_tpl->_count($_from) > 0){
  172. foreach ($_from as $_smarty_tpl->tpl_vars['combination']->key => $_smarty_tpl->tpl_vars['combination']->value){
  173. $_smarty_tpl->tpl_vars['idCombination']->value = $_smarty_tpl->tpl_vars['combination']->key;
  174. ?>
  175. addCombination(<?php echo intval($_smarty_tpl->tpl_vars['idCombination']->value);?>
  176. , new Array(<?php echo $_smarty_tpl->tpl_vars['combination']->value['list'];?>
  177. ), <?php echo $_smarty_tpl->tpl_vars['combination']->value['quantity'];?>
  178. , <?php echo $_smarty_tpl->tpl_vars['combination']->value['price'];?>
  179. , <?php echo $_smarty_tpl->tpl_vars['combination']->value['ecotax'];?>
  180. , <?php echo $_smarty_tpl->tpl_vars['combination']->value['id_image'];?>
  181. , '<?php echo addslashes($_smarty_tpl->tpl_vars['combination']->value['reference']);?>
  182. ', <?php echo $_smarty_tpl->tpl_vars['combination']->value['unit_impact'];?>
  183. , <?php echo $_smarty_tpl->tpl_vars['combination']->value['minimal_quantity'];?>
  184. );
  185. <?php }} ?>
  186. // Colors
  187. <?php if (count($_smarty_tpl->getVariable('colors')->value)>0){?>
  188. <?php if ($_smarty_tpl->getVariable('product')->value->id_color_default){?>var id_color_default = <?php echo intval($_smarty_tpl->getVariable('product')->value->id_color_default);?>
  189. ;<?php }?>
  190. <?php }?>
  191. <?php }?>
  192. //]]>
  193. </script>
  194. <?php $_template = new Smarty_Internal_Template(($_smarty_tpl->getVariable('tpl_dir')->value)."./breadcrumb.tpl", $_smarty_tpl->smarty, $_smarty_tpl, $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null);
  195. echo $_template->getRenderedTemplate();?><?php unset($_template);?>
  196. <div id="primary_block" class="clearfix">
  197. <h1><?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->name,'htmlall','UTF-8');?>
  198. </h1>
  199. <?php if (isset($_smarty_tpl->getVariable('adminActionDisplay',null,true,false)->value)&&$_smarty_tpl->getVariable('adminActionDisplay')->value){?>
  200. <div id="admin-action">
  201. <p><?php echo smartyTranslate(array('s'=>'This product is not visible to your customers.'),$_smarty_tpl);?>
  202. <input type="hidden" id="admin-action-product-id" value="<?php echo $_smarty_tpl->getVariable('product')->value->id;?>
  203. " />
  204. <input type="submit" value="<?php echo smartyTranslate(array('s'=>'Publish'),$_smarty_tpl);?>
  205. " class="exclusive" onclick="submitPublishProduct('<?php echo $_smarty_tpl->getVariable('base_dir')->value;?>
  206. <?php echo $_GET['ad'];?>
  207. ', 0)"/>
  208. <input type="submit" value="<?php echo smartyTranslate(array('s'=>'Back'),$_smarty_tpl);?>
  209. " class="exclusive" onclick="submitPublishProduct('<?php echo $_smarty_tpl->getVariable('base_dir')->value;?>
  210. <?php echo $_GET['ad'];?>
  211. ', 1)"/>
  212. </p>
  213. <div class="clear" ></div>
  214. <p id="admin-action-result"></p>
  215. </p>
  216. </div>
  217. <?php }?>
  218. <?php if (isset($_smarty_tpl->getVariable('confirmation',null,true,false)->value)&&$_smarty_tpl->getVariable('confirmation')->value){?>
  219. <p class="confirmation">
  220. <?php echo $_smarty_tpl->getVariable('confirmation')->value;?>
  221. </p>
  222. <?php }?>
  223. <!-- right infos-->
  224. <div id="pb-right-column">
  225. <!-- product img-->
  226. <div id="image-block">
  227. <?php if ($_smarty_tpl->getVariable('have_image')->value){?>
  228. <img src="<?php echo $_smarty_tpl->getVariable('link')->value->getImageLink($_smarty_tpl->getVariable('product')->value->link_rewrite,$_smarty_tpl->getVariable('cover')->value['id_image'],'large');?>
  229. "
  230. <?php if ($_smarty_tpl->getVariable('jqZoomEnabled')->value){?>class="jqzoom" alt="<?php echo $_smarty_tpl->getVariable('link')->value->getImageLink($_smarty_tpl->getVariable('product')->value->link_rewrite,$_smarty_tpl->getVariable('cover')->value['id_image'],'thickbox');?>
  231. "<?php }else{ ?> title="<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->name,'htmlall','UTF-8');?>
  232. " alt="<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->name,'htmlall','UTF-8');?>
  233. " <?php }?> id="bigpic" width="<?php echo $_smarty_tpl->getVariable('largeSize')->value['width'];?>
  234. " height="<?php echo $_smarty_tpl->getVariable('largeSize')->value['height'];?>
  235. " />
  236. <?php }else{ ?>
  237. <img src="<?php echo $_smarty_tpl->getVariable('img_prod_dir')->value;?>
  238. <?php echo $_smarty_tpl->getVariable('lang_iso')->value;?>
  239. -default-large.jpg" id="bigpic" alt="" title="<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->name,'htmlall','UTF-8');?>
  240. " width="<?php echo $_smarty_tpl->getVariable('largeSize')->value['width'];?>
  241. " height="<?php echo $_smarty_tpl->getVariable('largeSize')->value['height'];?>
  242. " />
  243. <?php }?>
  244. </div>
  245. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)&&count($_smarty_tpl->getVariable('images')->value)>0){?>
  246. <!-- thumbnails -->
  247. <div id="views_block" <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)&&count($_smarty_tpl->getVariable('images')->value)<2){?>class="hidden"<?php }?>>
  248. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)&&count($_smarty_tpl->getVariable('images')->value)>3){?><span class="view_scroll_spacer"><a id="view_scroll_left" class="hidden" title="<?php echo smartyTranslate(array('s'=>'Other views'),$_smarty_tpl);?>
  249. " href="javascript:{}"><?php echo smartyTranslate(array('s'=>'Previous'),$_smarty_tpl);?>
  250. </a></span><?php }?>
  251. <div id="thumbs_list">
  252. <ul id="thumbs_list_frame">
  253. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)){?>
  254. <?php $_smarty_tpl->tpl_vars['image'] = new Smarty_Variable;
  255. $_from = $_smarty_tpl->getVariable('images')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  256. $_smarty_tpl->tpl_vars['image']->index=-1;
  257. if ($_smarty_tpl->_count($_from) > 0){
  258. foreach ($_from as $_smarty_tpl->tpl_vars['image']->key => $_smarty_tpl->tpl_vars['image']->value){
  259. $_smarty_tpl->tpl_vars['image']->index++;
  260. $_smarty_tpl->tpl_vars['image']->first = $_smarty_tpl->tpl_vars['image']->index === 0;
  261. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['thumbnails']['first'] = $_smarty_tpl->tpl_vars['image']->first;
  262. ?>
  263. <?php $_smarty_tpl->tpl_vars['imageIds'] = new Smarty_variable(($_smarty_tpl->getVariable('product')->value->id)."-".($_smarty_tpl->tpl_vars['image']->value['id_image']), null, null);?>
  264. <li id="thumbnail_<?php echo $_smarty_tpl->tpl_vars['image']->value['id_image'];?>
  265. ">
  266. <a href="<?php echo $_smarty_tpl->getVariable('link')->value->getImageLink($_smarty_tpl->getVariable('product')->value->link_rewrite,$_smarty_tpl->getVariable('imageIds')->value,'thickbox');?>
  267. " rel="other-views" class="thickbox <?php if ($_smarty_tpl->getVariable('smarty')->value['foreach']['thumbnails']['first']){?>shown<?php }?>" title="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['image']->value['legend']);?>
  268. ">
  269. <img id="thumb_<?php echo $_smarty_tpl->tpl_vars['image']->value['id_image'];?>
  270. " src="<?php echo $_smarty_tpl->getVariable('link')->value->getImageLink($_smarty_tpl->getVariable('product')->value->link_rewrite,$_smarty_tpl->getVariable('imageIds')->value,'medium');?>
  271. " alt="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['image']->value['legend']);?>
  272. " height="<?php echo $_smarty_tpl->getVariable('mediumSize')->value['height'];?>
  273. " width="<?php echo $_smarty_tpl->getVariable('mediumSize')->value['width'];?>
  274. " />
  275. </a>
  276. </li>
  277. <?php }} ?>
  278. <?php }?>
  279. </ul>
  280. </div>
  281. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)&&count($_smarty_tpl->getVariable('images')->value)>3){?><a id="view_scroll_right" title="<?php echo smartyTranslate(array('s'=>'Other views'),$_smarty_tpl);?>
  282. " href="javascript:{}"><?php echo smartyTranslate(array('s'=>'Next'),$_smarty_tpl);?>
  283. </a><?php }?>
  284. </div>
  285. <?php }?>
  286. <?php if (isset($_smarty_tpl->getVariable('images',null,true,false)->value)&&count($_smarty_tpl->getVariable('images')->value)>1){?><p class="align_center clear"><span id="wrapResetImages" style="display: none;"><img src="<?php echo $_smarty_tpl->getVariable('img_dir')->value;?>
  287. icon/cancel_16x18.gif" alt="<?php echo smartyTranslate(array('s'=>'Cancel'),$_smarty_tpl);?>
  288. " width="16" height="18"/> <a id="resetImages" href="<?php echo $_smarty_tpl->getVariable('link')->value->getProductLink($_smarty_tpl->getVariable('product')->value);?>
  289. " onclick="$('span#wrapResetImages').hide('slow');return (false);"><?php echo smartyTranslate(array('s'=>'Display all pictures'),$_smarty_tpl);?>
  290. </a></span></p><?php }?>
  291. <!-- usefull links-->
  292. <ul id="usefull_link_block">
  293. <?php if ($_smarty_tpl->getVariable('HOOK_EXTRA_LEFT')->value){?><?php echo $_smarty_tpl->getVariable('HOOK_EXTRA_LEFT')->value;?>
  294. <?php }?>
  295. <li><a href="javascript:print();"><?php echo smartyTranslate(array('s'=>'Print'),$_smarty_tpl);?>
  296. </a><br class="clear" /></li>
  297. <?php if ($_smarty_tpl->getVariable('have_image')->value&&!$_smarty_tpl->getVariable('jqZoomEnabled')->value){?>
  298. <li><span id="view_full_size" class="span_link"><?php echo smartyTranslate(array('s'=>'View full size'),$_smarty_tpl);?>
  299. </span></li>
  300. <?php }?>
  301. </ul>
  302. </div>
  303. <!-- left infos-->
  304. <div id="pb-left-column">
  305. <?php if ($_smarty_tpl->getVariable('product')->value->description_short||count($_smarty_tpl->getVariable('packItems')->value)>0){?>
  306. <div id="short_description_block">
  307. <?php if ($_smarty_tpl->getVariable('product')->value->description_short){?>
  308. <div id="short_description_content" class="rte align_justify"><?php echo $_smarty_tpl->getVariable('product')->value->description_short;?>
  309. </div>
  310. <?php }?>
  311. <?php if ($_smarty_tpl->getVariable('product')->value->description){?>
  312. <p class="buttons_bottom_block"><a href="javascript:{}" class="button"><?php echo smartyTranslate(array('s'=>'More details'),$_smarty_tpl);?>
  313. </a></p>
  314. <?php }?>
  315. <?php if (count($_smarty_tpl->getVariable('packItems')->value)>0){?>
  316. <h3><?php echo smartyTranslate(array('s'=>'Pack content'),$_smarty_tpl);?>
  317. </h3>
  318. <?php $_smarty_tpl->tpl_vars['packItem'] = new Smarty_Variable;
  319. $_from = $_smarty_tpl->getVariable('packItems')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  320. if ($_smarty_tpl->_count($_from) > 0){
  321. foreach ($_from as $_smarty_tpl->tpl_vars['packItem']->key => $_smarty_tpl->tpl_vars['packItem']->value){
  322. ?>
  323. <div class="pack_content">
  324. <?php echo $_smarty_tpl->tpl_vars['packItem']->value['pack_quantity'];?>
  325. x <a href="<?php echo $_smarty_tpl->getVariable('link')->value->getProductLink($_smarty_tpl->tpl_vars['packItem']->value['id_product'],$_smarty_tpl->tpl_vars['packItem']->value['link_rewrite'],$_smarty_tpl->tpl_vars['packItem']->value['category']);?>
  326. "><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['packItem']->value['name'],'htmlall','UTF-8');?>
  327. </a>
  328. <p><?php echo $_smarty_tpl->tpl_vars['packItem']->value['description_short'];?>
  329. </p>
  330. </div>
  331. <?php }} ?>
  332. <?php }?>
  333. </div>
  334. <?php }?>
  335. <?php if (isset($_smarty_tpl->getVariable('colors',null,true,false)->value)&&$_smarty_tpl->getVariable('colors')->value){?>
  336. <!-- colors -->
  337. <div id="color_picker">
  338. <p><?php echo smartyTranslate(array('s'=>'Pick a color:','js'=>1),$_smarty_tpl);?>
  339. </p>
  340. <div class="clear"></div>
  341. <ul id="color_to_pick_list">
  342. <?php $_smarty_tpl->tpl_vars['color'] = new Smarty_Variable;
  343. $_smarty_tpl->tpl_vars['id_attribute'] = new Smarty_Variable;
  344. $_from = $_smarty_tpl->getVariable('colors')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  345. if ($_smarty_tpl->_count($_from) > 0){
  346. foreach ($_from as $_smarty_tpl->tpl_vars['color']->key => $_smarty_tpl->tpl_vars['color']->value){
  347. $_smarty_tpl->tpl_vars['id_attribute']->value = $_smarty_tpl->tpl_vars['color']->key;
  348. ?>
  349. <li><a id="color_<?php echo intval($_smarty_tpl->tpl_vars['id_attribute']->value);?>
  350. " class="color_pick" style="background: <?php echo $_smarty_tpl->tpl_vars['color']->value['value'];?>
  351. ;" onclick="updateColorSelect(<?php echo intval($_smarty_tpl->tpl_vars['id_attribute']->value);?>
  352. );$('#wrapResetImages').show('slow');" title="<?php echo $_smarty_tpl->tpl_vars['color']->value['name'];?>
  353. "><?php if (file_exists((($_smarty_tpl->getVariable('col_img_dir')->value).($_smarty_tpl->tpl_vars['id_attribute']->value)).('.jpg'))){?><img src="<?php echo $_smarty_tpl->getVariable('img_col_dir')->value;?>
  354. <?php echo $_smarty_tpl->tpl_vars['id_attribute']->value;?>
  355. .jpg" alt="<?php echo $_smarty_tpl->tpl_vars['color']->value['name'];?>
  356. " width="20" height="20" /><?php }?></a></li>
  357. <?php }} ?>
  358. </ul>
  359. <div class="clear"></div>
  360. </div>
  361. <?php }?>
  362. <?php if (($_smarty_tpl->getVariable('product')->value->show_price&&!isset($_smarty_tpl->getVariable('restricted_country_mode',null,true,false)->value))||isset($_smarty_tpl->getVariable('groups',null,true,false)->value)||$_smarty_tpl->getVariable('product')->value->reference||(isset($_smarty_tpl->getVariable('HOOK_PRODUCT_ACTIONS',null,true,false)->value)&&$_smarty_tpl->getVariable('HOOK_PRODUCT_ACTIONS')->value)){?>
  363. <!-- add to cart form-->
  364. <form id="buy_block" <?php if ($_smarty_tpl->getVariable('PS_CATALOG_MODE')->value&&!isset($_smarty_tpl->getVariable('groups',null,true,false)->value)&&$_smarty_tpl->getVariable('product')->value->quantity>0){?>class="hidden"<?php }?> action="<?php echo $_smarty_tpl->getVariable('link')->value->getPageLink('cart.php');?>
  365. " method="post">
  366. <!-- hidden datas -->
  367. <p class="hidden">
  368. <input type="hidden" name="token" value="<?php echo $_smarty_tpl->getVariable('static_token')->value;?>
  369. " />
  370. <input type="hidden" name="id_product" value="<?php echo intval($_smarty_tpl->getVariable('product')->value->id);?>
  371. " id="product_page_product_id" />
  372. <input type="hidden" name="add" value="1" />
  373. <input type="hidden" name="id_product_attribute" id="idCombination" value="" />
  374. </p>
  375. <!-- prices -->
  376. <?php if ($_smarty_tpl->getVariable('product')->value->show_price&&!isset($_smarty_tpl->getVariable('restricted_country_mode',null,true,false)->value)&&!$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?>
  377. <p class="price">
  378. <?php if (!$_smarty_tpl->getVariable('priceDisplay')->value||$_smarty_tpl->getVariable('priceDisplay')->value==2){?>
  379. <?php $_smarty_tpl->tpl_vars['productPrice'] = new Smarty_variable($_smarty_tpl->getVariable('product')->value->getPrice(true,@NULL,2), null, null);?>
  380. <?php $_smarty_tpl->tpl_vars['productPriceWithoutRedution'] = new Smarty_variable($_smarty_tpl->getVariable('product')->value->getPriceWithoutReduct(false,@NULL), null, null);?>
  381. <?php }elseif($_smarty_tpl->getVariable('priceDisplay')->value==1){?>
  382. <?php $_smarty_tpl->tpl_vars['productPrice'] = new Smarty_variable($_smarty_tpl->getVariable('product')->value->getPrice(false,@NULL,2), null, null);?>
  383. <?php $_smarty_tpl->tpl_vars['productPriceWithoutRedution'] = new Smarty_variable($_smarty_tpl->getVariable('product')->value->getPriceWithoutReduct(true,@NULL), null, null);?>
  384. <?php }?>
  385. <?php if ($_smarty_tpl->getVariable('product')->value->on_sale){?>
  386. <img src="<?php echo $_smarty_tpl->getVariable('img_dir')->value;?>
  387. onsale_<?php echo $_smarty_tpl->getVariable('lang_iso')->value;?>
  388. .gif" alt="<?php echo smartyTranslate(array('s'=>'On sale'),$_smarty_tpl);?>
  389. " class="on_sale_img"/>
  390. <span class="on_sale"><?php echo smartyTranslate(array('s'=>'On sale!'),$_smarty_tpl);?>
  391. </span>
  392. <?php }elseif($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction']&&$_smarty_tpl->getVariable('productPriceWithoutRedution')->value>$_smarty_tpl->getVariable('productPrice')->value){?>
  393. <span class="discount"><?php echo smartyTranslate(array('s'=>'Reduced price!'),$_smarty_tpl);?>
  394. </span>
  395. <?php }?>
  396. <br />
  397. <span class="our_price_display">
  398. <?php if ($_smarty_tpl->getVariable('priceDisplay')->value>=0&&$_smarty_tpl->getVariable('priceDisplay')->value<=2){?>
  399. <span id="our_price_display"><?php echo Product::convertPrice(array('price'=>$_smarty_tpl->getVariable('productPrice')->value),$_smarty_tpl);?>
  400. </span>
  401. <?php if ($_smarty_tpl->getVariable('tax_enabled')->value&&((isset($_smarty_tpl->getVariable('display_tax_label',null,true,false)->value)&&$_smarty_tpl->getVariable('display_tax_label')->value==1)||!isset($_smarty_tpl->getVariable('display_tax_label',null,true,false)->value))){?>
  402. <?php if ($_smarty_tpl->getVariable('priceDisplay')->value==1){?><?php echo smartyTranslate(array('s'=>'tax excl.'),$_smarty_tpl);?>
  403. <?php }else{ ?><?php echo smartyTranslate(array('s'=>'tax incl.'),$_smarty_tpl);?>
  404. <?php }?>
  405. <?php }?>
  406. <?php }?>
  407. </span>
  408. <?php if ($_smarty_tpl->getVariable('priceDisplay')->value==2){?>
  409. <br />
  410. <span id="pretaxe_price"><span id="pretaxe_price_display"><?php echo Product::convertPrice(array('price'=>$_smarty_tpl->getVariable('product')->value->getPrice(false,@NULL)),$_smarty_tpl);?>
  411. </span>&nbsp;<?php echo smartyTranslate(array('s'=>'tax excl.'),$_smarty_tpl);?>
  412. </span>
  413. <?php }?>
  414. <br />
  415. </p>
  416. <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction']){?>
  417. <p id="old_price"><span class="bold">
  418. <?php if ($_smarty_tpl->getVariable('priceDisplay')->value>=0&&$_smarty_tpl->getVariable('priceDisplay')->value<=2){?>
  419. <?php if ($_smarty_tpl->getVariable('productPriceWithoutRedution')->value>$_smarty_tpl->getVariable('productPrice')->value){?>
  420. <span id="old_price_display"><?php echo Product::convertPrice(array('price'=>$_smarty_tpl->getVariable('productPriceWithoutRedution')->value),$_smarty_tpl);?>
  421. </span>
  422. <?php if ($_smarty_tpl->getVariable('tax_enabled')->value&&$_smarty_tpl->getVariable('display_tax_label')->value==1){?>
  423. <?php if ($_smarty_tpl->getVariable('priceDisplay')->value==1){?><?php echo smartyTranslate(array('s'=>'tax excl.'),$_smarty_tpl);?>
  424. <?php }else{ ?><?php echo smartyTranslate(array('s'=>'tax incl.'),$_smarty_tpl);?>
  425. <?php }?>
  426. <?php }?>
  427. <?php }?>
  428. <?php }?>
  429. </span>
  430. </p>
  431. <?php }?>
  432. <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction_type']=='percentage'){?>
  433. <p id="reduction_percent"><?php echo smartyTranslate(array('s'=>'(price reduced by'),$_smarty_tpl);?>
  434. <span id="reduction_percent_display"><?php echo $_smarty_tpl->getVariable('product')->value->specificPrice['reduction']*100;?>
  435. </span> %<?php echo smartyTranslate(array('s'=>')'),$_smarty_tpl);?>
  436. </p>
  437. <?php }?>
  438. <?php if (count($_smarty_tpl->getVariable('packItems')->value)){?>
  439. <p class="pack_price"><?php echo smartyTranslate(array('s'=>'instead of'),$_smarty_tpl);?>
  440. <span style="text-decoration: line-through;"><?php echo Product::convertPrice(array('price'=>$_smarty_tpl->getVariable('product')->value->getNoPackPrice()),$_smarty_tpl);?>
  441. </span></p>
  442. <br class="clear" />
  443. <?php }?>
  444. <?php if ($_smarty_tpl->getVariable('product')->value->ecotax!=0){?>
  445. <p class="price-ecotax"><?php echo smartyTranslate(array('s'=>'include'),$_smarty_tpl);?>
  446. <span id="ecotax_price_display"><?php if ($_smarty_tpl->getVariable('priceDisplay')->value==2){?><?php echo Product::convertAndFormatPrice($_smarty_tpl->getVariable('ecotax_tax_exc')->value);?>
  447. <?php }else{ ?><?php echo Product::convertAndFormatPrice($_smarty_tpl->getVariable('ecotax_tax_inc')->value);?>
  448. <?php }?></span> <?php echo smartyTranslate(array('s'=>'for green tax'),$_smarty_tpl);?>
  449. <?php if ($_smarty_tpl->getVariable('product')->value->specificPrice&&$_smarty_tpl->getVariable('product')->value->specificPrice['reduction']){?>
  450. <br /><?php echo smartyTranslate(array('s'=>'(not impacted by the discount)'),$_smarty_tpl);?>
  451. <?php }?>
  452. </p>
  453. <?php }?>
  454. <?php if (!empty($_smarty_tpl->getVariable('product',null,true,false)->value->unity)&&$_smarty_tpl->getVariable('product')->value->unit_price_ratio>0.000000){?>
  455. <?php echo smarty_function_math(array('equation'=>"pprice / punit_price",'pprice'=>$_smarty_tpl->getVariable('productPrice')->value,'punit_price'=>$_smarty_tpl->getVariable('product')->value->unit_price_ratio,'assign'=>'unit_price'),$_smarty_tpl);?>
  456. <p class="unit-price"><span id="unit_price_display"><?php echo Product::convertPrice(array('price'=>$_smarty_tpl->getVariable('unit_price')->value),$_smarty_tpl);?>
  457. </span> <?php echo smartyTranslate(array('s'=>'per'),$_smarty_tpl);?>
  458. <?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->unity,'htmlall','UTF-8');?>
  459. </p>
  460. <?php }?>
  461. <?php }?>
  462. <?php if (isset($_smarty_tpl->getVariable('groups',null,true,false)->value)){?>
  463. <!-- attributes -->
  464. <div id="attributes">
  465. <?php $_smarty_tpl->tpl_vars['group'] = new Smarty_Variable;
  466. $_smarty_tpl->tpl_vars['id_attribute_group'] = new Smarty_Variable;
  467. $_from = $_smarty_tpl->getVariable('groups')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  468. if ($_smarty_tpl->_count($_from) > 0){
  469. foreach ($_from as $_smarty_tpl->tpl_vars['group']->key => $_smarty_tpl->tpl_vars['group']->value){
  470. $_smarty_tpl->tpl_vars['id_attribute_group']->value = $_smarty_tpl->tpl_vars['group']->key;
  471. ?>
  472. <?php if (count($_smarty_tpl->tpl_vars['group']->value['attributes'])){?>
  473. <p>
  474. <label for="group_<?php echo intval($_smarty_tpl->tpl_vars['id_attribute_group']->value);?>
  475. "><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['group']->value['name'],'htmlall','UTF-8');?>
  476. :</label>
  477. <?php $_smarty_tpl->tpl_vars["groupName"] = new Smarty_variable("group_".($_smarty_tpl->tpl_vars['id_attribute_group']->value), null, null);?>
  478. <select name="<?php echo $_smarty_tpl->getVariable('groupName')->value;?>
  479. " id="group_<?php echo intval($_smarty_tpl->tpl_vars['id_attribute_group']->value);?>
  480. " onchange="javascript:findCombination();<?php if (count($_smarty_tpl->getVariable('colors')->value)>0){?>$('#wrapResetImages').show('slow');<?php }?>;">
  481. <?php $_smarty_tpl->tpl_vars['group_attribute'] = new Smarty_Variable;
  482. $_smarty_tpl->tpl_vars['id_attribute'] = new Smarty_Variable;
  483. $_from = $_smarty_tpl->tpl_vars['group']->value['attributes']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  484. if ($_smarty_tpl->_count($_from) > 0){
  485. foreach ($_from as $_smarty_tpl->tpl_vars['group_attribute']->key => $_smarty_tpl->tpl_vars['group_attribute']->value){
  486. $_smarty_tpl->tpl_vars['id_attribute']->value = $_smarty_tpl->tpl_vars['group_attribute']->key;
  487. ?>
  488. <option value="<?php echo intval($_smarty_tpl->tpl_vars['id_attribute']->value);?>
  489. "<?php if ((isset($_GET[$_smarty_tpl->getVariable('groupName',null,true,false)->value])&&intval($_GET[$_smarty_tpl->getVariable('groupName')->value])==$_smarty_tpl->tpl_vars['id_attribute']->value)||$_smarty_tpl->tpl_vars['group']->value['default']==$_smarty_tpl->tpl_vars['id_attribute']->value){?> selected="selected"<?php }?> title="<?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['group_attribute']->value,'htmlall','UTF-8');?>
  490. "><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['group_attribute']->value,'htmlall','UTF-8');?>
  491. </option>
  492. <?php }} ?>
  493. </select>
  494. </p>
  495. <?php }?>
  496. <?php }} ?>
  497. </div>
  498. <?php }?>
  499. <p id="product_reference" <?php if (isset($_smarty_tpl->getVariable('groups',null,true,false)->value)||!$_smarty_tpl->getVariable('product')->value->reference){?>style="display: none;"<?php }?>><label for="product_reference"><?php echo smartyTranslate(array('s'=>'Reference :'),$_smarty_tpl);?>
  500. </label><span class="editable"><?php echo smarty_modifier_escape($_smarty_tpl->getVariable('product')->value->reference,'htmlall','UTF-8');?>
  501. </span></p>
  502. <!-- quantity wanted -->
  503. <p id="quantity_wanted_p"<?php if ((!$_smarty_tpl->getVariable('allow_oosp')->value&&$_smarty_tpl->getVariable('product')->value->quantity<=0)||$_smarty_tpl->getVariable('virtual')->value||!$_smarty_tpl->getVariable('product')->value->available_for_order||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?> style="display: none;"<?php }?>>
  504. <label><?php echo smartyTranslate(array('s'=>'Quantity :'),$_smarty_tpl);?>
  505. </label>
  506. <input type="text" name="qty" id="quantity_wanted" class="text" value="<?php if (isset($_smarty_tpl->getVariable('quantityBackup',null,true,false)->value)){?><?php echo intval($_smarty_tpl->getVariable('quantityBackup')->value);?>
  507. <?php }else{ ?><?php if ($_smarty_tpl->getVariable('product')->value->minimal_quantity>1){?><?php echo $_smarty_tpl->getVariable('product')->value->minimal_quantity;?>
  508. <?php }else{ ?>1<?php }?><?php }?>" size="2" maxlength="3" <?php if ($_smarty_tpl->getVariable('product')->value->minimal_quantity>1){?>onkeyup="checkMinimalQuantity(<?php echo $_smarty_tpl->getVariable('product')->value->minimal_quantity;?>
  509. );"<?php }?> />
  510. </p>
  511. <!-- minimal quantity wanted -->
  512. <p id="minimal_quantity_wanted_p"<?php if ($_smarty_tpl->getVariable('product')->value->minimal_quantity<=1||!$_smarty_tpl->getVariable('product')->value->available_for_order||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?> style="display: none;"<?php }?>><?php echo smartyTranslate(array('s'=>'You must add '),$_smarty_tpl);?>
  513. <b id="minimal_quantity_label"><?php echo $_smarty_tpl->getVariable('product')->value->minimal_quantity;?>
  514. </b><?php echo smartyTranslate(array('s'=>' as a minimum quantity to buy this product.'),$_smarty_tpl);?>
  515. </p>
  516. <?php if ($_smarty_tpl->getVariable('product')->value->minimal_quantity>1){?>
  517. <script type="text/javascript">
  518. checkMinimalQuantity();
  519. </script>
  520. <?php }?>
  521. <!-- availability -->
  522. <p id="availability_statut"<?php if (($_smarty_tpl->getVariable('product')->value->quantity<=0&&!$_smarty_tpl->getVariable('product')->value->available_later&&$_smarty_tpl->getVariable('allow_oosp')->value)||($_smarty_tpl->getVariable('product')->value->quantity>0&&!$_smarty_tpl->getVariable('product')->value->available_now)||!$_smarty_tpl->getVariable('product')->value->available_for_order||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?> style="display: none;"<?php }?>>
  523. <span id="availability_label"><?php echo smartyTranslate(array('s'=>'Availability:'),$_smarty_tpl);?>
  524. </span>
  525. <span id="availability_value"<?php if ($_smarty_tpl->getVariable('product')->value->quantity<=0){?> class="warning_inline"<?php }?>>
  526. <?php if ($_smarty_tpl->getVariable('product')->value->quantity<=0){?><?php if ($_smarty_tpl->getVariable('allow_oosp')->value){?><?php echo $_smarty_tpl->getVariable('product')->value->available_later;?>
  527. <?php }else{ ?><?php echo smartyTranslate(array('s'=>'This product is no longer in stock'),$_smarty_tpl);?>
  528. <?php }?><?php }else{ ?><?php echo $_smarty_tpl->getVariable('product')->value->available_now;?>
  529. <?php }?>
  530. </span>
  531. </p>
  532. <!-- number of item in stock -->
  533. <?php if (($_smarty_tpl->getVariable('display_qties')->value==1&&!$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value&&$_smarty_tpl->getVariable('product')->value->available_for_order)){?>
  534. <p id="pQuantityAvailable"<?php if ($_smarty_tpl->getVariable('product')->value->quantity<=0){?> style="display: none;"<?php }?>>
  535. <span id="quantityAvailable"><?php echo intval($_smarty_tpl->getVariable('product')->value->quantity);?>
  536. </span>
  537. <span <?php if ($_smarty_tpl->getVariable('product')->value->quantity>1){?> style="display: none;"<?php }?> id="quantityAvailableTxt"><?php echo smartyTranslate(array('s'=>'item in stock'),$_smarty_tpl);?>
  538. </span>
  539. <span <?php if ($_smarty_tpl->getVariable('product')->value->quantity==1){?> style="display: none;"<?php }?> id="quantityAvailableTxtMultiple"><?php echo smartyTranslate(array('s'=>'items in stock'),$_smarty_tpl);?>
  540. </span>
  541. </p>
  542. <?php }?>
  543. <!-- Out of stock hook -->
  544. <p id="oosHook"<?php if ($_smarty_tpl->getVariable('product')->value->quantity>0){?> style="display: none;"<?php }?>>
  545. <?php echo $_smarty_tpl->getVariable('HOOK_PRODUCT_OOS')->value;?>
  546. </p>
  547. <p class="warning_inline" id="last_quantities"<?php if (($_smarty_tpl->getVariable('product')->value->quantity>$_smarty_tpl->getVariable('last_qties')->value||$_smarty_tpl->getVariable('product')->value->quantity<=0)||$_smarty_tpl->getVariable('allow_oosp')->value||!$_smarty_tpl->getVariable('product')->value->available_for_order||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?> style="display: none;"<?php }?> ><?php echo smartyTranslate(array('s'=>'Warning: Last items in stock!'),$_smarty_tpl);?>
  548. </p>
  549. <?php if ($_smarty_tpl->getVariable('product')->value->online_only){?>
  550. <p><?php echo smartyTranslate(array('s'=>'Online only'),$_smarty_tpl);?>
  551. </p>
  552. <?php }?>
  553. <p<?php if ((!$_smarty_tpl->getVariable('allow_oosp')->value&&$_smarty_tpl->getVariable('product')->value->quantity<=0)||!$_smarty_tpl->getVariable('product')->value->available_for_order||(isset($_smarty_tpl->getVariable('restricted_country_mode',null,true,false)->value)&&$_smarty_tpl->getVariable('restricted_country_mode')->value)||$_smarty_tpl->getVariable('PS_CATALOG_MODE')->value){?> style="display: none;"<?php }?> id="add_to_cart" class="buttons_bottom_block"><input type="submit" name="Submit" value="<?php echo smartyTranslate(array('s'=>'Add to cart'),$_smarty_tpl);?>
  554. " class="exclusive" /></p>
  555. <?php if (isset($_smarty_tpl->getVariable('HOOK_PRODUCT_ACTIONS',null,true,false)->value)&&$_smarty_tpl->getVariable('HOOK_PRODUCT_ACTIONS')->value){?><?php echo $_smarty_tpl->getVariable('HOOK_PRODUCT_ACTIONS')->value;?>
  556. <?php }?>
  557. <div class="clear"></div>
  558. </form>
  559. <?php }?>
  560. <?php if ($_smarty_tpl->getVariable('HOOK_EXTRA_RIGHT')->value){?><?php echo $_smarty_tpl->getVariable('HOOK_EXTRA_RIGHT')->value;?>
  561. <?php }?>
  562. </div>
  563. </div>
  564. <?php if ($_smarty_tpl->getVariable('quantity_discounts')->value){?>
  565. <!-- quantity discount -->
  566. <ul class="idTabs">
  567. <li><a style="cursor: pointer" class="selected"><?php echo smartyTranslate(array('s'=>'Quantity discount'),$_smarty_tpl);?>
  568. </a></li>
  569. </ul>
  570. <div id="quantityDiscount">
  571. <table class="std">
  572. <tr>
  573. <?php $_smarty_tpl->tpl_vars['quantity_discount'] = new Smarty_Variable;
  574. $_from = $_smarty_tpl->getVariable('quantity_discounts')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  575. if ($_smarty_tpl->_count($_from) > 0){
  576. foreach ($_from as $_smarty_tpl->tpl_vars['quantity_discount']->key => $_smarty_tpl->tpl_vars['quantity_discount']->value){
  577. ?>
  578. <th><?php echo intval($_smarty_tpl->tpl_vars['quantity_discount']->value['quantity']);?>
  579. <?php if (intval($_smarty_tpl->tpl_vars['quantity_discount']->value['quantity'])>1){?>
  580. <?php echo smartyTranslate(array('s'=>'quantities'),$_smarty_tpl);?>
  581. <?php }else{ ?>
  582. <?php echo smartyTranslate(array('s'=>'quantity'),$_smarty_tpl);?>
  583. <?php }?>
  584. </th>
  585. <?php }} ?>
  586. </tr>
  587. <tr>
  588. <?php $_smarty_tpl->tpl_vars['quantity_discount'] = new Smarty_Variable;
  589. $_from = $_smarty_tpl->getVariable('quantity_discounts')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  590. if ($_smarty_tpl->_count($_from) > 0){
  591. foreach ($_from as $_smarty_tpl->tpl_vars['quantity_discount']->key => $_smarty_tpl->tpl_vars['quantity_discount']->value){
  592. ?>
  593. <td>
  594. <?php if ($_smarty_tpl->tpl_vars['quantity_discount']->value['price']!=0||$_smarty_tpl->tpl_vars['quantity_discount']->value['reduction_type']=='amount'){?>
  595. -<?php echo Product::convertPrice(array('price'=>floatval($_smarty_tpl->tpl_vars['quantity_discount']->value['real_value'])),$_smarty_tpl);?>
  596. <?php }else{ ?>
  597. -<?php echo floatval($_smarty_tpl->tpl_vars['quantity_discount']->value['real_value']);?>
  598. %
  599. <?php }?>
  600. </td>
  601. <?php }} ?>
  602. </tr>
  603. </table>
  604. </div>
  605. <?php }?>
  606. <?php echo $_smarty_tpl->getVariable('HOOK_PRODUCT_FOOTER')->value;?>
  607. <!-- description and features -->
  608. <?php if ($_smarty_tpl->getVariable('product')->value->description||$_smarty_tpl->getVariable('features')->value||$_smarty_tpl->getVariable('accessories')->value||$_smarty_tpl->getVariable('HOOK_PRODUCT_TAB')->value||$_smarty_tpl->getVariable('attachments')->value){?>
  609. <div id="more_info_block" class="clear">
  610. <ul id="more_info_tabs" class="idTabs idTabsShort">
  611. <?php if ($_smarty_tpl->getVariable('product')->value->description){?><li><a id="more_info_tab_more_info" href="#idTab1"><?php echo smartyTranslate(array('s'=>'More info'),$_smarty_tpl);?>
  612. </a></li><?php }?>
  613. <?php if ($_smarty_tpl->getVariable('features')->value){?><li><a id="more_info_tab_data_sheet" href="#idTab2"><?php echo smartyTranslate(array('s'=>'Data sheet'),$_smarty_tpl);?>
  614. </a></li><?php }?>
  615. <?php if ($_smarty_tpl->getVariable('attachments')->value){?><li><a id="more_info_tab_attachments" href="#idTab9"><?php echo smartyTranslate(array('s'=>'Download'),$_smarty_tpl);?>
  616. </a></li><?php }?>
  617. <?php if (isset($_smarty_tpl->getVariable('accessories',null,true,false)->value)&&$_smarty_tpl->getVariable('accessories')->value){?><li><a href="#idTab4"><?php echo smartyTranslate(array('s'=>'Accessories'),$_smarty_tpl);?>
  618. </a></li><?php }?>
  619. <?php echo $_smarty_tpl->getVariable('HOOK_PRODUCT_TAB')->value;?>
  620. </ul>
  621. <div id="more_info_sheets" class="sheets align_justify">
  622. <?php if ($_smarty_tpl->getVariable('product')->value->description){?>
  623. <!-- full description -->
  624. <div id="idTab1" class="rte"><?php echo $_smarty_tpl->getVariable('product')->value->description;?>
  625. </div>
  626. <?php }?>
  627. <?php if ($_smarty_tpl->getVariable('features')->value){?>
  628. <!-- product's features -->
  629. <ul id="idTab2" class="bullet">
  630. <?php $_smarty_tpl->tpl_vars['feature'] = new Smarty_Variable;
  631. $_from = $_smarty_tpl->getVariable('features')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  632. if ($_smarty_tpl->_count($_from) > 0){
  633. foreach ($_from as $_smarty_tpl->tpl_vars['feature']->key => $_smarty_tpl->tpl_vars['feature']->value){
  634. ?>
  635. <li><span><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['feature']->value['name'],'htmlall','UTF-8');?>
  636. </span> <?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['feature']->value['value'],'htmlall','UTF-8');?>
  637. </li>
  638. <?php }} ?>
  639. </ul>
  640. <?php }?>
  641. <?php if ($_smarty_tpl->getVariable('attachments')->value){?>
  642. <ul id="idTab9" class="bullet">
  643. <?php $_smarty_tpl->tpl_vars['attachment'] = new Smarty_Variable;
  644. $_from = $_smarty_tpl->getVariable('attachments')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  645. if ($_smarty_tpl->_count($_from) > 0){
  646. foreach ($_from as $_smarty_tpl->tpl_vars['attachment']->key => $_smarty_tpl->tpl_vars['attachment']->value){
  647. ?>
  648. <li><a href="<?php echo $_smarty_tpl->getVariable('link')->value->getPageLink('attachment.php',true);?>
  649. ?id_attachment=<?php echo $_smarty_tpl->tpl_vars['attachment']->value['id_attachment'];?>
  650. "><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['attachment']->value['name'],'htmlall','UTF-8');?>
  651. </a><br /><?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['attachment']->value['description'],'htmlall','UTF-8');?>
  652. </li>
  653. <?php }} ?>
  654. </ul>
  655. <?php }?>
  656. <?php if (isset($_smarty_tpl->getVariable('accessories',null,true,false)->value)&&$_smarty_tpl->getVariable('accessories')->value){?>
  657. <!-- accessories -->
  658. <ul id="idTab4" class="bullet">
  659. <div class="block products_block accessories_block clearfix">
  660. <div class="block_content">
  661. <ul>
  662. <?php $_smarty_tpl->tpl_vars['accessory'] = new Smarty_Variable;
  663. $_from = $_smarty_tpl->getVariable('accessories')->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  664. $_smarty_tpl->tpl_vars['accessory']->total= $_smarty_tpl->_count($_from);
  665. $_smarty_tpl->tpl_vars['accessory']->iteration=0;
  666. $_smarty_tpl->tpl_vars['accessory']->index=-1;
  667. if ($_smarty_tpl->tpl_vars['accessory']->total > 0){
  668. foreach ($_from as $_smarty_tpl->tpl_vars['accessory']->key => $_smarty_tpl->tpl_vars['accessory']->value){
  669. $_smarty_tpl->tpl_vars['accessory']->iteration++;
  670. $_smarty_tpl->tpl_vars['accessory']->index++;
  671. $_smarty_tpl->tpl_vars['accessory']->first = $_smarty_tpl->tpl_vars['accessory']->index === 0;
  672. $_smarty_tpl->tpl_vars['accessory']->last = $_smarty_tpl->tpl_vars['accessory']->iteration === $_smarty_tpl->tpl_vars['accessory']->total;
  673. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['accessories_list']['first'] = $_smarty_tpl->tpl_vars['accessory']->first;
  674. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['accessories_list']['last'] = $_smarty_tpl->tpl_vars['accessory']->last;
  675. ?>
  676. <?php $_smarty_tpl->tpl_vars['accessoryLink'] = new Smarty_variable($_smarty_tpl->getVariable('link')->value->getProductLink($_smarty_tpl->tpl_vars['accessory']->value['id_product'],$_smarty_tpl->tpl_vars['accessory']->value['link_rewrite'],$_smarty_tpl->tpl_vars['accessory']->value['category']), null, null);?>
  677. <li class="ajax_block_product <?php if ($_smarty_tpl->getVariable('smarty')->value['foreach']['accessories_list']['first']){?>first_item<?php }elseif($_smarty_tpl->getVariable('smarty')->value['foreach']['accessories_list']['last']){?>last_item<?php }else{ ?>item<?php }?> product_accessories_description">
  678. <h5><a href="<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('accessoryLink')->value,'htmlall','UTF-8');?>
  679. "><?php echo smarty_modifier_escape(smarty_modifier_truncate($_smarty_tpl->tpl_vars['accessory']->value['name'],22,'...',true),'htmlall','UTF-8');?>
  680. </a></h5>
  681. <div class="product_desc">
  682. <a href="<?php echo smarty_modifier_escape($_smarty_tpl->getVariable('accessoryLink')->value,'htmlall','UTF-8');?>
  683. " title="<?php echo smarty_modifier_escape($_smarty_tpl->tpl_vars['accessory']->value['legend'],'htmlall','UTF-8');?>
  684. " class="product_image"><im…

Large files files are truncated, but you can click here to view the full file