Advertisement
Guest User

Untitled

a guest
Nov 18th, 2012
205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 31.93 KB | None | 0 0
  1. {*
  2. * 2007-2012 PrestaShop
  3. *
  4. * NOTICE OF LICENSE
  5. *
  6. * This source file is subject to the Academic Free License (AFL 3.0)
  7. * that is bundled with this package in the file LICENSE.txt.
  8. * It is also available through the world-wide-web at this URL:
  9. * http://opensource.org/licenses/afl-3.0.php
  10. * If you did not receive a copy of the license and are unable to
  11. * obtain it through the world-wide-web, please send an email
  12. * to license@prestashop.com so we can send you a copy immediately.
  13. *
  14. * DISCLAIMER
  15. *
  16. * Do not edit or add to this file if you wish to upgrade PrestaShop to newer
  17. * versions in the future. If you wish to customize PrestaShop for your
  18. * needs please refer to http://www.prestashop.com for more information.
  19. *
  20. * @author PrestaShop SA <contact@prestashop.com>
  21. * @copyright 2007-2012 PrestaShop SA
  22. * @version Release: $Revision: 14460 $
  23. * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
  24. * International Registered Trademark & Property of PrestaShop SA
  25. *}
  26.  
  27. {include file="$tpl_dir./errors.tpl"}
  28. {if $errors|@count == 0}
  29. <script type="text/javascript">
  30. // <![CDATA[
  31.  
  32. // PrestaShop internal settings
  33. var currencySign = '{$currencySign|html_entity_decode:2:"UTF-8"}';
  34. var currencyRate = '{$currencyRate|floatval}';
  35. var currencyFormat = '{$currencyFormat|intval}';
  36. var currencyBlank = '{$currencyBlank|intval}';
  37. var taxRate = {$tax_rate|floatval};
  38. var jqZoomEnabled = {if $jqZoomEnabled}true{else}false{/if};
  39.  
  40. //JS Hook
  41. var oosHookJsCodeFunctions = new Array();
  42.  
  43. // Parameters
  44. var id_product = '{$product->id|intval}';
  45. var productHasAttributes = {if isset($groups)}true{else}false{/if};
  46. var quantitiesDisplayAllowed = {if $display_qties == 1}true{else}false{/if};
  47. var quantityAvailable = {if $display_qties == 1 && $product->quantity}{$product->quantity}{else}0{/if};
  48. var allowBuyWhenOutOfStock = {if $allow_oosp == 1}true{else}false{/if};
  49. var availableNowValue = '{$product->available_now|escape:'quotes':'UTF-8'}';
  50. var availableLaterValue = '{$product->available_later|escape:'quotes':'UTF-8'}';
  51. var productPriceTaxExcluded = {$product->getPriceWithoutReduct(true)|default:'null'} - {$product->ecotax};
  52. var reduction_percent = {if $product->specificPrice AND $product->specificPrice.reduction AND $product->specificPrice.reduction_type == 'percentage'}{$product->specificPrice.reduction*100}{else}0{/if};
  53. var reduction_price = {if $product->specificPrice AND $product->specificPrice.reduction AND $product->specificPrice.reduction_type == 'amount'}{$product->specificPrice.reduction}{else}0{/if};
  54. var specific_price = {if $product->specificPrice AND $product->specificPrice.price}{$product->specificPrice.price}{else}0{/if};
  55. var specific_currency = {if $product->specificPrice AND $product->specificPrice.id_currency}true{else}false{/if};
  56. var group_reduction = '{$group_reduction}';
  57. var default_eco_tax = {$product->ecotax};
  58. var ecotaxTax_rate = {$ecotaxTax_rate};
  59. var currentDate = '{$smarty.now|date_format:'%Y-%m-%d %H:%M:%S'}';
  60. var maxQuantityToAllowDisplayOfLastQuantityMessage = {$last_qties};
  61. var noTaxForThisProduct = {if $no_tax == 1}true{else}false{/if};
  62. var displayPrice = {$priceDisplay};
  63. var productReference = '{$product->reference|escape:'htmlall':'UTF-8'}';
  64. var productAvailableForOrder = {if (isset($restricted_country_mode) AND $restricted_country_mode) OR $PS_CATALOG_MODE}'0'{else}'{$product->available_for_order}'{/if};
  65. var productShowPrice = '{if !$PS_CATALOG_MODE}{$product->show_price}{else}0{/if}';
  66. var productUnitPriceRatio = '{$product->unit_price_ratio}';
  67. var idDefaultImage = {if isset($cover.id_image_only)}{$cover.id_image_only}{else}0{/if};
  68. var ipa_default = {if isset($ipa_default)}{$ipa_default}{/if};
  69.  
  70. // Customizable field
  71. var img_ps_dir = '{$img_ps_dir}';
  72. var customizationFields = new Array();
  73. {assign var='imgIndex' value=0}
  74. {assign var='textFieldIndex' value=0}
  75. {foreach from=$customizationFields item='field' name='customizationFields'}
  76. {assign var="key" value="pictures_`$product->id`_`$field.id_customization_field`"}
  77. customizationFields[{$smarty.foreach.customizationFields.index|intval}] = new Array();
  78. customizationFields[{$smarty.foreach.customizationFields.index|intval}][0] = '{if $field.type|intval == 0}img{$imgIndex++}{else}textField{$textFieldIndex++}{/if}';
  79. customizationFields[{$smarty.foreach.customizationFields.index|intval}][1] = {if $field.type|intval == 0 && isset($pictures.$key) && $pictures.$key}2{else}{$field.required|intval}{/if};
  80. {/foreach}
  81.  
  82. // Images
  83. var img_prod_dir = '{$img_prod_dir}';
  84. var combinationImages = new Array();
  85.  
  86. {if isset($combinationImages)}
  87. {foreach from=$combinationImages item='combination' key='combinationId' name='f_combinationImages'}
  88. combinationImages[{$combinationId}] = new Array();
  89. {foreach from=$combination item='image' name='f_combinationImage'}
  90. combinationImages[{$combinationId}][{$smarty.foreach.f_combinationImage.index}] = {$image.id_image|intval};
  91. {/foreach}
  92. {/foreach}
  93. {/if}
  94.  
  95. combinationImages[0] = new Array();
  96. {if isset($images)}
  97. {foreach from=$images item='image' name='f_defaultImages'}
  98. combinationImages[0][{$smarty.foreach.f_defaultImages.index}] = {$image.id_image};
  99. {/foreach}
  100. {/if}
  101.  
  102. // Translations
  103. var doesntExist = '{l s='The product does not exist in this model. Please choose another.' js=1}';
  104. var doesntExistNoMore = '{l s='This product is no longer in stock' js=1}';
  105. var doesntExistNoMoreBut = '{l s='with those attributes but is available with others' js=1}';
  106. var uploading_in_progress = '{l s='Uploading in progress, please wait...' js=1}';
  107. var fieldRequired = '{l s='Please fill in all required fields, then save the customization.' js=1}';
  108.  
  109. {if isset($groups)}
  110. // Combinations
  111. {foreach from=$combinations key=idCombination item=combination}
  112. addCombination({$idCombination|intval}, new Array({$combination.list}), {$combination.quantity}, {$combination.price}, {$combination.ecotax}, {$combination.id_image}, '{$combination.reference|addslashes}', {$combination.unit_impact}, {$combination.minimal_quantity});
  113. {/foreach}
  114. // Colors
  115. {if $colors|@count > 0}
  116. {if $product->id_color_default}var id_color_default = {$product->id_color_default|intval};{/if}
  117. {/if}
  118. {/if}
  119. //]]>
  120. </script>
  121.  
  122. {include file="$tpl_dir./breadcrumb.tpl"}
  123. <div id="primary_block" class="clearfix" itemscope itemtype="http://data-vocabulary.org/Product">
  124.  
  125. {if isset($adminActionDisplay) && $adminActionDisplay}
  126. <div id="admin-action">
  127. <p>{l s='This product is not visible to your customers.'}
  128. <input type="hidden" id="admin-action-product-id" value="{$product->id}" />
  129. <input type="submit" value="{l s='Publish'}" class="exclusive" onclick="submitPublishProduct('{$base_dir}{$smarty.get.ad}', 0)"/>
  130. <input type="submit" value="{l s='Back'}" class="exclusive" onclick="submitPublishProduct('{$base_dir}{$smarty.get.ad}', 1)"/>
  131. </p>
  132. <div class="clear" ></div>
  133. <p id="admin-action-result"></p>
  134. </p>
  135. </div>
  136. {/if}
  137.  
  138. {if isset($confirmation) && $confirmation}
  139. <p class="confirmation">
  140. {$confirmation}
  141. </p>
  142. {/if}
  143.  
  144. <!-- left infos-->
  145. <div id="pb-left-column">
  146. <!-- product img-->
  147. <div id="image-block">
  148. {if $have_image}
  149. <a href="{$link->getImageLink($product->link_rewrite, $cover.id_image)}{**{$link->getImageLink($product->link_rewrite, $cover.id_image, 'thickbox')}**}" rel="other-views" class="thickbox" title="{$product->name|escape:'htmlall':'UTF-8'}">
  150. <img itemprop="image" src="{$link->getImageLink($product->link_rewrite, $cover.id_image, 'large')}"
  151. {if $jqZoomEnabled}class="jqzoom" alt="{$link->getImageLink($product->link_rewrite, $cover.id_image, 'thickbox')}"{else} title="{$product->name|escape:'htmlall':'UTF-8'}" alt="{$product->name|escape:'htmlall':'UTF-8'}" {/if} id="bigpic" width="{$largeSize.width}" height="{$largeSize.height}" />
  152. </a>
  153. {else}
  154. <img itemprop="image" src="{$img_prod_dir}{$lang_iso}-default-large.jpg" id="bigpic" alt="" title="{$cover.legend|escape:'htmlall':'UTF-8'}" width="{$largeSize.width}" height="{$largeSize.height}" />
  155. {/if}
  156. </div>
  157.  
  158. {**<!-- usefull links-->
  159. <ul id="usefull_link_block">
  160. <li><a href="javascript:print();">{l s='Print'}</a><br class="clear" /></li>
  161. {if $have_image && !$jqZoomEnabled}
  162. <li><span id="view_full_size" class="span_link">{l s='View full size'}</span></li>
  163. {/if}
  164. </ul>**}
  165. </div>
  166.  
  167. <!-- right infos-->
  168. <div id="pb-right-column">
  169. <h1 itemprop="name">{$product->name|escape:'htmlall':'UTF-8'}</h1>
  170. {if $HOOK_EXTRA_RIGHT}{$HOOK_EXTRA_RIGHT}{/if}
  171. {if $product->description_short OR $packItems|@count > 0}
  172. <div id="short_description_block">
  173. {if $product->description_short}
  174. <div id="short_description_content" class="rte align_justify" itemprop="description">
  175. {**<h3>{l s='Why would you like it?'}</h3>**}{$product->description_short}
  176. </div>
  177. {/if}
  178. {**{if $product->description}
  179. <p class="buttons_bottom_block"><a href="javascript:{ldelim}{rdelim}" class="button">{l s='More details'}</a></p>
  180. {/if}**}
  181. {if $packItems|@count > 0}
  182. <h3>{l s='Pack content'}</h3>
  183. {foreach from=$packItems item=packItem}
  184. <div class="pack_content">
  185. {$packItem.pack_quantity} x <a href="{$link->getProductLink($packItem.id_product, $packItem.link_rewrite, $packItem.category)}">{$packItem.name|escape:'htmlall':'UTF-8'}</a>
  186. <p>{$packItem.description_short}</p>
  187. </div>
  188. {/foreach}
  189. {/if}
  190. </div>
  191. {/if}
  192.  
  193. {if isset($colors) && $colors}
  194. <!-- colors -->
  195. <div id="color_picker">
  196. <p>{l s='Pick a color:' js=1}</p>
  197. <div class="clear"></div>
  198. <ul id="color_to_pick_list">
  199. {foreach from=$colors key='id_attribute' item='color'}
  200. <li><a id="color_{$id_attribute|intval}" class="color_pick" style="background: {$color.value};" onclick="updateColorSelect({$id_attribute|intval});$('#wrapResetImages').show('slow');" title="{$color.name}">{if file_exists($col_img_dir|cat:$id_attribute|cat:'.jpg')}<img src="{$img_col_dir}{$id_attribute}.jpg" alt="{$color.name}" width="20" height="20" />{/if}</a></li>
  201. {/foreach}
  202. </ul>
  203. <div class="clear"></div>
  204. </div>
  205. {/if}
  206.  
  207. {if ($product->show_price AND !isset($restricted_country_mode)) OR isset($groups) OR $product->reference OR (isset($HOOK_PRODUCT_ACTIONS) && $HOOK_PRODUCT_ACTIONS)}
  208. <!-- add to cart form-->
  209. <form id="buy_block" itemprop="offerDetails" itemscope itemtype="http://data-vocabulary.org/Offer" {if $PS_CATALOG_MODE AND !isset($groups) AND $product->quantity > 0}class="hidden"{/if} action="{$link->getPageLink('cart.php')}" method="post">
  210.  
  211. <!-- hidden datas -->
  212. <p class="hidden">
  213. <input type="hidden" name="token" value="{$static_token}" />
  214. <input type="hidden" name="id_product" value="{$product->id|intval}" id="product_page_product_id" />
  215. <input type="hidden" name="add" value="1" />
  216. <input type="hidden" name="id_product_attribute" id="idCombination" value="" />
  217. </p>
  218.  
  219. <!-- prices -->
  220. {if $product->show_price AND !isset($restricted_country_mode) AND !$PS_CATALOG_MODE}
  221. {if !$priceDisplay || $priceDisplay == 2}
  222. {assign var='productPrice' value=$product->getPrice(true, $smarty.const.NULL, 2)}
  223. {assign var='productPriceWithoutRedution' value=$product->getPriceWithoutReduct(false, $smarty.const.NULL)}
  224. {elseif $priceDisplay == 1}
  225. {assign var='productPrice' value=$product->getPrice(false, $smarty.const.NULL, 2)}
  226. {assign var='productPriceWithoutRedution' value=$product->getPriceWithoutReduct(true, $smarty.const.NULL)}
  227. {/if}
  228. {if $product->on_sale}
  229. <p class="price_discount">
  230. <img src="{$img_dir}onsale_{$lang_iso}.gif" alt="{l s='On sale'}" class="on_sale_img"/>
  231. <span class="on_sale">{l s='On sale!'}</span>
  232. </p>
  233. {elseif $product->specificPrice AND $product->specificPrice.reduction AND $productPriceWithoutRedution > $productPrice}
  234. {** <p class="price_discount">
  235. {if $product->specificPrice AND $product->specificPrice.reduction}
  236. {if $priceDisplay >= 0 && $priceDisplay <= 2}
  237. {if $productPriceWithoutRedution > $productPrice}
  238. <span id="old_price_display">{convertPrice price=$productPriceWithoutRedution}</span>
  239. {if $tax_enabled && $display_tax_label == 1}
  240. {if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if}
  241. {/if}
  242. {/if}
  243. {/if}
  244.  
  245. {/if}**}
  246. {**<span class="discount">{l s='Reduced price!'}</span>**}
  247. </p>
  248. {/if}
  249. <p class="price">
  250. <span class="our_price_display">
  251. {if $priceDisplay >= 0 && $priceDisplay <= 2}
  252. <span id="our_price_display">
  253. <meta itemprop="currency" content="{$currencyISO}" />
  254. <span itemprop="price">{$productPrice}{**{convertPrice price=$productPrice}**}</span> {$currencySign|html_entity_decode:2:"UTF-8"}
  255. </span>
  256. {if $tax_enabled && ((isset($display_tax_label) && $display_tax_label == 1) OR !isset($display_tax_label))}
  257. {if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if}
  258. {/if}
  259. {/if}
  260. </span>
  261. {if $priceDisplay == 2}
  262. <br />
  263. <span id="pretaxe_price"><span id="pretaxe_price_display">{convertPrice price=$product->getPrice(false, $smarty.const.NULL, 2)}</span>&nbsp;{l s='tax excl.'}</span>
  264. {/if}
  265. </p>
  266. {**{if $product->specificPrice AND $product->specificPrice.reduction_type == 'percentage'}
  267. <p id="reduction_percent">{l s='(price reduced by'} <span id="reduction_percent_display">{$product->specificPrice.reduction*100}</span> %{l s=')'}</p>
  268. {/if}**}
  269. {if $packItems|@count}
  270. <p class="pack_price">{l s='instead of'} <span style="text-decoration: line-through;">{convertPrice price=$product->getNoPackPrice()}</span></p>
  271. <br class="clear" />
  272. {/if}
  273. {if $product->ecotax != 0}
  274. <p class="price-ecotax">{l s='include'} <span id="ecotax_price_display">{if $priceDisplay == 2}{$ecotax_tax_exc|convertAndFormatPrice}{else}{$ecotax_tax_inc|convertAndFormatPrice}{/if}</span> {l s='for green tax'}
  275. {if $product->specificPrice AND $product->specificPrice.reduction}
  276. <br />{l s='(not impacted by the discount)'}
  277. {/if}
  278. </p>
  279. {/if}
  280. {if !empty($product->unity) && $product->unit_price_ratio > 0.000000}
  281. {math equation="pprice / punit_price" pprice=$productPrice punit_price=$product->unit_price_ratio assign=unit_price}
  282. <p class="unit-price"><span id="unit_price_display">{convertPrice price=$unit_price}</span> {l s='per'} {$product->unity|escape:'htmlall':'UTF-8'}</p>
  283. {/if}
  284. {*close if for show price*}
  285. {/if}
  286.  
  287. {if isset($groups)}
  288. <!-- attributes -->
  289. <div id="attributes">
  290. {foreach from=$groups key=id_attribute_group item=group}
  291. {if $group.attributes|@count}
  292. <p>
  293. <label for="group_{$id_attribute_group|intval}">{$group.name|escape:'htmlall':'UTF-8'} :</label>
  294. {assign var="groupName" value="group_$id_attribute_group"}
  295. <select name="{$groupName}" id="group_{$id_attribute_group|intval}" onchange="javascript:findCombination();{if $colors|@count > 0}$('#wrapResetImages').show('slow');{/if};">
  296. {foreach from=$group.attributes key=id_attribute item=group_attribute}
  297. <option value="{$id_attribute|intval}"{if (isset($smarty.get.$groupName) && $smarty.get.$groupName|intval == $id_attribute) || $group.default == $id_attribute} selected="selected"{/if} title="{$group_attribute|escape:'htmlall':'UTF-8'}">{$group_attribute|escape:'htmlall':'UTF-8'}</option>
  298. {/foreach}
  299. </select>
  300. </p>
  301. {/if}
  302. {/foreach}
  303. </div>
  304. {/if}
  305.  
  306. {**<p id="product_reference" {if isset($groups) OR !$product->reference}style="display: none;"{/if}><label for="product_reference">{l s='Reference :'} </label><span class="editable">{$product->reference|escape:'htmlall':'UTF-8'}</span></p>**}
  307.  
  308. <!-- minimal quantity wanted -->
  309. <p id="minimal_quantity_wanted_p"{if $product->minimal_quantity <= 1 OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if}>{l s='You must add '} <b id="minimal_quantity_label">{$product->minimal_quantity}</b> {l s=' as a minimum quantity to buy this product.'}</p>
  310. {if $product->minimal_quantity > 1}
  311. <script type="text/javascript">
  312. checkMinimalQuantity();
  313. </script>
  314. {/if}
  315. <meta itemprop="availability" content="in_stock" />
  316. {**<!-- availability -->
  317. <p id="availability_statut"{if ($product->quantity <= 0 && !$product->available_later && $allow_oosp) OR ($product->quantity > 0 && !$product->available_now) OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if}>
  318. <span id="availability_label">{l s='Availability:'}</span>
  319. <span id="availability_value"{if $product->quantity <= 0} class="warning_inline"{/if}>
  320. {if $product->quantity <= 0}{if $allow_oosp}{$product->available_later}{else}{l s='This product is no longer in stock'}{/if}{else}{$product->available_now}{/if}
  321. </span>
  322. </p>** }
  323.  
  324. {**<!-- number of item in stock -->
  325. {if ($display_qties == 1 && !$PS_CATALOG_MODE && $product->available_for_order)}
  326. <p id="pQuantityAvailable"{if $product->quantity <= 0} style="display: none;"{/if}>
  327. <span id="quantityAvailable">{$product->quantity|intval}</span>
  328. <span {if $product->quantity > 1} style="display: none;"{/if} id="quantityAvailableTxt">{l s='item in stock'}</span>
  329. <span {if $product->quantity == 1} style="display: none;"{/if} id="quantityAvailableTxtMultiple">{l s='items in stock'}</span>
  330. </p>
  331. {/if}**}
  332. <!-- Out of stock hook -->
  333. {if !$allow_oosp}
  334. <p id="oosHook"{if $product->quantity > 0} style="display: none;"{/if}>
  335. {$HOOK_PRODUCT_OOS}
  336. </p>
  337. {/if}
  338.  
  339. <p class="warning_inline" id="last_quantities"{if ($product->quantity > $last_qties OR $product->quantity <= 0) OR $allow_oosp OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if} >{l s='Warning: Last items in stock!'}</p>
  340.  
  341. {if $product->online_only}
  342. <p>{l s='Online only'}</p>
  343. {/if}
  344.  
  345. <!-- quantity wanted -->
  346. {**<p id="quantity_wanted_p"{if (!$allow_oosp && $product->quantity <= 0) OR $virtual OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if}>
  347. <label>{l s='Quantity :'}</label>
  348. <input type="text" name="qty" id="quantity_wanted" class="text" value="{if isset($quantityBackup)}{$quantityBackup|intval}{else}{if $product->minimal_quantity > 1}{$product->minimal_quantity}{else}1{/if}{/if}" size="2" maxlength="3" {if $product->minimal_quantity > 1}onkeyup="checkMinimalQuantity({$product->minimal_quantity});"{/if} />
  349. </p>**}
  350.  
  351. <p{if (!$allow_oosp && $product->quantity <= 0) OR !$product->available_for_order OR (isset($restricted_country_mode) AND $restricted_country_mode) OR $PS_CATALOG_MODE} style="display: none;"{/if} id="add_to_cart" class="buttons_bottom_block"><input type="submit" name="Submit" value="{l s='Add to cart'}" class="exclusive" />
  352. <span id="added" style="display: none;"><span class="text">{l s='Added to Cart'}&nbsp;</span><a href="{$link->getPageLink("$order_process.php", true)}">{l s='Pay Now?'}</a></span>
  353. </p>
  354. {if isset($HOOK_PRODUCT_ACTIONS) && $HOOK_PRODUCT_ACTIONS}{$HOOK_PRODUCT_ACTIONS}{/if}
  355. <div class="clear"></div>
  356. </form>
  357. {/if}
  358.  
  359. {if $features}
  360. <div id="pegi">
  361. {foreach from=$features item=feature}
  362. {if $feature.name == 'PEGI'}
  363. <img class="pegi_rating" src="{$img_dir}PEGI/pegi{$feature.value}.gif" alt="{$feature.name|escape:'htmlall':'UTF-8'} {$feature.value|escape:'htmlall':'UTF-8'}" title="{if $feature.value == 3}{l s='The content of games given this rating is considered suitable for all age groups. Some violence in a comical context (typically Bugs Bunny or Tom & Jerry cartoon-like forms of violence) is acceptable. The child should not be able to associate the character on the screen with real life characters, they should be totally fantasy. The game should not contain any sounds or pictures that are likely to scare or frighten young children. No bad language should be heard.'}{elseif $feature.value == 7}{l s='Any game that would normally be rated at 3 but contains some possibly frightening scenes or sounds may be considered suitable in this category.'}{elseif $feature.value == 12}{l s='Videogames that show violence of a slightly more graphic nature towards fantasy character and/or non graphic violence towards human-looking characters or recognisable animals, as well as videogames that show nudity of a slightly more graphic nature would fall in this age category. Any bad language in this category must be mild and fall short of sexual expletives.'}{elseif $feature.value == 16}{l s='This rating is applied once the depiction of violence (or sexual activity) reaches a stage that looks the same as would be expected in real life. More extreme bad language, the concept of the use of tobacco and drugs and the depiction of criminal activities can be content of games that are rated 16.'}{elseif $feature.value == 18}{l s='The adult classification is applied when the level of violence reaches a stage where it becomes a depiction of gross violence and/or includes elements of specific types of violence. Gross violence is the most difficult to define since it can be very subjective in many cases, but in general terms it can be classed as the depictions of violence that would make the viewer feel a sense of revulsion.'}{/if}">
  364. {else}
  365. <img src="{$img_dir}PEGI/{$feature.id_feature}.gif" alt="{$feature.name|escape:'htmlall':'UTF-8'}" title="{$feature.value|escape:'htmlall':'UTF-8'}" />
  366. {/if}
  367. {/foreach}
  368. </div>
  369. {/if}
  370. </div>
  371. </div>
  372.  
  373. {if $quantity_discounts}
  374. <!-- quantity discount -->
  375. <ul class="idTabs">
  376. <li><a style="cursor: pointer" class="selected">{l s='Quantity discount'}</a></li>
  377. </ul>
  378. <div id="quantityDiscount">
  379. <table class="std">
  380. <tr>
  381. {foreach from=$quantity_discounts item='quantity_discount' name='quantity_discounts'}
  382. <th>{$quantity_discount.quantity|intval}
  383. {if $quantity_discount.quantity|intval > 1}
  384. {l s='quantities'}
  385. {else}
  386. {l s='quantity'}
  387. {/if}
  388. </th>
  389. {/foreach}
  390. </tr>
  391. <tr>
  392. {foreach from=$quantity_discounts item='quantity_discount' name='quantity_discounts'}
  393. <td>
  394. {if $quantity_discount.price != 0 OR $quantity_discount.reduction_type == 'amount'}
  395. -{convertPrice price=$quantity_discount.real_value|floatval}
  396. {else}
  397. -{$quantity_discount.real_value|floatval}%
  398. {/if}
  399. </td>
  400. {/foreach}
  401. </tr>
  402. </table>
  403. </div>
  404. {/if}
  405.  
  406. {$HOOK_PRODUCT_FOOTER}
  407. <div id="social_block"><h4 class="spread">{l s='Spread good things'}:</h4>
  408. <div class="fb"><div class="fb-like" data-send="true" data-layout="button_count" data-show-faces="false"></div></div>
  409. <div class="gplus"><g:plusone size="medium"></g:plusone></div>
  410. {if $HOOK_EXTRA_LEFT}{$HOOK_EXTRA_LEFT}{/if}
  411. </div>
  412.  
  413. <!-- description and features -->
  414. {if $product->description || $features || $accessories || $HOOK_PRODUCT_TAB || $attachments}
  415. <div id="more_info_block" class="clear">
  416. {**<ul id="more_info_tabs" class="idTabs idTabsShort">
  417. {if $product->description}<li><a id="more_info_tab_more_info" href="#idTab1">{l s='More info'}</a></li>{/if}
  418. **}{**{if $features}<li><a id="more_info_tab_data_sheet" href="#idTab2">{l s='Data sheet'}</a></li>{/if}**}{**
  419. {if $attachments}<li><a id="more_info_tab_attachments" href="#idTab9">{l s='Download'}</a></li>{/if}
  420. {if isset($accessories) AND $accessories}<li><a href="#idTab4">{l s='Accessories'}</a></li>{/if}
  421. {$HOOK_PRODUCT_TAB}
  422. </ul>**}
  423. <div id="more_info_sheets" class="sheets align_justify">
  424. {if $product->description}
  425. <!-- full description -->
  426. <div id="idTab1" class="rte" itemprop="description">{$product->description}</div>
  427. {/if}
  428. {**{if $features}
  429. <!-- product's features -->
  430. <ul id="idTab2" class="bullet">
  431. {foreach from=$features item=feature}
  432. <li><span>{$feature.name|escape:'htmlall':'UTF-8'}</span> {$feature.value|escape:'htmlall':'UTF-8'}</li>
  433. {/foreach}
  434. </ul>
  435. {/if}**}
  436. {if $attachments}
  437. <ul id="idTab9" class="bullet">
  438. {foreach from=$attachments item=attachment}
  439. <li><a href="{$link->getPageLink('attachment.php', true)}?id_attachment={$attachment.id_attachment}">{$attachment.name|escape:'htmlall':'UTF-8'}</a><br />{$attachment.description|escape:'htmlall':'UTF-8'}</li>
  440. {/foreach}
  441. </ul>
  442. {/if}
  443. {if isset($accessories) AND $accessories}
  444. <!-- accessories -->
  445. <ul id="idTab4" class="bullet">
  446. <div class="block products_block accessories_block clearfix">
  447. <div class="block_content">
  448. <ul>
  449. {foreach from=$accessories item=accessory name=accessories_list}
  450. {assign var='accessoryLink' value=$link->getProductLink($accessory.id_product, $accessory.link_rewrite, $accessory.category)}
  451. <li class="ajax_block_product {if $smarty.foreach.accessories_list.first}first_item{elseif $smarty.foreach.accessories_list.last}last_item{else}item{/if} product_accessories_description">
  452. <h5><a href="{$accessoryLink|escape:'htmlall':'UTF-8'}">{$accessory.name|truncate:22:'...':true|escape:'htmlall':'UTF-8'}</a></h5>
  453. <div class="product_desc">
  454. <a href="{$accessoryLink|escape:'htmlall':'UTF-8'}" title="{$accessory.legend|escape:'htmlall':'UTF-8'}" class="product_image"><img src="{$link->getImageLink($accessory.link_rewrite, $accessory.id_image, 'medium')}" alt="{$accessory.legend|escape:'htmlall':'UTF-8'}" width="{$mediumSize.width}" height="{$mediumSize.height}" /></a>
  455. <a href="{$accessoryLink|escape:'htmlall':'UTF-8'}" title="{l s='More'}" class="product_description">{$accessory.description_short|strip_tags|truncate:70:'...'}</a>
  456. </div>
  457. <p class="product_accessories_price">
  458. {if $accessory.show_price AND !isset($restricted_country_mode) AND !$PS_CATALOG_MODE}<span class="price">{if $priceDisplay != 1}{displayWtPrice p=$accessory.price}{else}{displayWtPrice p=$accessory.price_tax_exc}{/if}</span>{/if}
  459. <a class="button" href="{$accessoryLink|escape:'htmlall':'UTF-8'}" title="{l s='View'}">{l s='View'}</a>
  460. {if ($accessory.allow_oosp || $accessory.quantity > 0) AND $accessory.available_for_order AND !isset($restricted_country_mode) AND !$PS_CATALOG_MODE}
  461. <a class="exclusive button ajax_add_to_cart_button" href="{$link->getPageLink('cart.php')}?qty=1&amp;id_product={$accessory.id_product|intval}&amp;token={$static_token}&amp;add" rel="ajax_id_product_{$accessory.id_product|intval}" title="{l s='Add to cart'}">{l s='Add to cart'}</a>
  462. {else}
  463. <span class="exclusive">{l s='Add to cart'}</span>
  464. <span class="availability">{if (isset($accessory.quantity_all_versions) && $accessory.quantity_all_versions > 0)}{l s='Product available with different options'}{else}{l s='Out of stock'}{/if}</span>
  465. {/if}
  466. </p>
  467. </li>
  468.  
  469. {/foreach}
  470. </ul>
  471. </div>
  472. </div>
  473. </ul>
  474. {/if}
  475. {$HOOK_PRODUCT_TAB_CONTENT}
  476. </div>
  477. </div>
  478. {/if}
  479.  
  480. <!-- Customizable products -->
  481. {if $product->customizable}
  482. <ul class="idTabs">
  483. <li><a style="cursor: pointer">{l s='Product customization'}</a></li>
  484. </ul>
  485. <div class="customization_block">
  486. <form method="post" action="{$customizationFormTarget}" enctype="multipart/form-data" id="customizationForm">
  487. <p>
  488. <img src="{$img_dir}icon/infos.gif" alt="Informations" />
  489. {l s='After saving your customized product, remember to add it to your cart.'}
  490. {if $product->uploadable_files}<br />{l s='Allowed file formats are: GIF, JPG, PNG'}{/if}
  491. </p>
  492. {if $product->uploadable_files|intval}
  493. <h2>{l s='Pictures'}</h2>
  494. <ul id="uploadable_files">
  495. {counter start=0 assign='customizationField'}
  496. {foreach from=$customizationFields item='field' name='customizationFields'}
  497. {if $field.type == 0}
  498. <li class="customizationUploadLine{if $field.required} required{/if}">{assign var='key' value='pictures_'|cat:$product->id|cat:'_'|cat:$field.id_customization_field}
  499. {if isset($pictures.$key)}<div class="customizationUploadBrowse">
  500. <img src="{$pic_dir}{$pictures.$key}_small" alt="" />
  501. <a href="{$link->getProductDeletePictureLink($product, $field.id_customization_field)}" title="{l s='Delete'}" >
  502. <img src="{$img_dir}icon/delete.gif" alt="{l s='Delete'}" class="customization_delete_icon" width="11" height="13" />
  503. </a>
  504. </div>{/if}
  505. <div class="customizationUploadBrowse"><input type="file" name="file{$field.id_customization_field}" id="img{$customizationField}" class="customization_block_input {if isset($pictures.$key)}filled{/if}" />{if $field.required}<sup>*</sup>{/if}
  506. <div class="customizationUploadBrowseDescription">{if !empty($field.name)}{$field.name}{else}{l s='Please select an image file from your hard drive'}{/if}</div></div>
  507. </li>
  508. {counter}
  509. {/if}
  510. {/foreach}
  511. </ul>
  512. {/if}
  513. <div class="clear"></div>
  514. {if $product->text_fields|intval}
  515. <h2>{l s='Texts'}</h2>
  516. <ul id="text_fields">
  517. {counter start=0 assign='customizationField'}
  518. {foreach from=$customizationFields item='field' name='customizationFields'}
  519. {if $field.type == 1}
  520. <li class="customizationUploadLine{if $field.required} required{/if}">{assign var='key' value='textFields_'|cat:$product->id|cat:'_'|cat:$field.id_customization_field}
  521. {if !empty($field.name)}{$field.name}{/if}{if $field.required}<sup>*</sup>{/if}<textarea type="text" name="textField{$field.id_customization_field}" id="textField{$customizationField}" rows="1" cols="40" class="customization_block_input" />{if isset($textFields.$key)}{$textFields.$key|stripslashes}{/if}</textarea>
  522. </li>
  523. {counter}
  524. {/if}
  525. {/foreach}
  526. </ul>
  527. {/if}
  528. <p style="clear: left;" id="customizedDatas">
  529. <input type="hidden" name="ipa_customization" id="ipa_customization" value="{$ipa_customization}" />
  530. <input type="hidden" name="quantityBackup" id="quantityBackup" value="" />
  531. <input type="hidden" name="submitCustomizedDatas" value="1" />
  532. <input type="button" class="button" value="{l s='Save'}" onclick="javascript:saveCustomization()" />
  533. <span id="ajax-loader" style="display:none"><img src="{$img_ps_dir}loader.gif" alt="loader" /></span>
  534. </p>
  535. </form>
  536. <p class="clear required"><sup>*</sup> {l s='required fields'}</p>
  537. </div>
  538. {/if}
  539.  
  540. {if $packItems|@count > 0}
  541. <div>
  542. <h2>{l s='Pack content'}</h2>
  543. {include file="$tpl_dir./product-list.tpl" products=$packItems}
  544. </div>
  545. {/if}
  546.  
  547. {/if}
  548.  
  549. {if isset($images) && count($images) > 1}
  550. <!-- thumbnails -->
  551. <div id="views_block">
  552. <h3>{l s='Pictures'}</h3>
  553. <div id="thumbs_list">
  554. <ul id="thumbs_list_frame">
  555. {if isset($images)}
  556. {foreach from=$images item=image name=thumbnails}
  557. {if $smarty.foreach.thumbnails.index != 0}
  558. {assign var=imageIds value="`$product->id`-`$image.id_image`"}
  559. <li id="thumbnail_{$image.id_image}">
  560. <a href="{$link->getImageLink($product->link_rewrite, $imageIds)}" rel="other-views" class="thickbox {if (isset($image.cover) AND $image.cover == 1) OR (!isset($image.cover) AND $smarty.foreach.thumbnails.first)}shown{/if}" title="{$image.legend|htmlspecialchars}">
  561. <img id="thumb_{$image.id_image}" src="{$link->getImageLink($product->link_rewrite, $imageIds, 'medium')}" alt="{$image.legend|htmlspecialchars}" height="{$mediumSize.height}" width="{$mediumSize.width}" />
  562. </a>
  563. </li>
  564. {/if}
  565. {/foreach}
  566. {/if}
  567. </ul>
  568. </div>
  569. <p class="howto magnify">{l s='Click on the image to zoom in'}</p>
  570. </div>
  571. {/if}
  572. <h3>{l s='Comments'}</h3>
  573. <div class="fb-comments" data-num-posts="3" data-width="604" href="{$smarty.server.HTTP_HOST}{$smarty.server.REQUEST_URI}"></div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement