diff --git a/themes/default/js/product.js b/themes/default/js/product.js index 755ba2024..e97e7446c 100644 --- a/themes/default/js/product.js +++ b/themes/default/js/product.js @@ -414,21 +414,14 @@ function displayImage(domAAroundImgThumb, no_animation) { if (typeof(no_animation) == 'undefined') no_animation = false; - if (domAAroundImgThumb.attr('href')) { - var newSrc = domAAroundImgThumb.attr('href').replace('thickbox','large'); - if(typeof(bigpicSrc) == 'undefined' || bigpicSrc == '') - bigpicSrc = $('#bigpic').attr('src'); - if (bigpicSrc != newSrc) + var newSrc = domAAroundImgThumb.attr('href').replace('thickbox', 'large'); + if ($('#bigpic').attr('src') != newSrc) { - //fadeOut is too slow, displayImage can be called again before bigpic source has really changed so we use a global bigpicSrc - bigpicSrc = newSrc; - $('#bigpic').fadeOut((no_animation ? 0 : 'fast'), function(){ - $(this).attr('src', newSrc).show(); - if (typeof(jqZoomEnabled) != 'undefined' && jqZoomEnabled) - $(this).attr('alt', domAAroundImgThumb.attr('href')); - }); + $('#bigpic').attr('src', newSrc); + if (typeof(jqZoomEnabled) != 'undefined' && jqZoomEnabled) + $(this).attr('alt', domAAroundImgThumb.attr('href')); } $('#views_block li a').removeClass('shown'); $(domAAroundImgThumb).addClass('shown'); @@ -481,7 +474,7 @@ function refreshProductImages(id_product_attribute) $('#thumbs_list').trigger('goto', 0); for (var i = 0; i < combinationImages[id_product_attribute].length; i++) $('#thumbnail_' + parseInt(combinationImages[id_product_attribute][i])).show(); - if (parseInt($('#thumbs_list_frame >li').length) != parseInt($('#thumbs_list_frame >li:visible').length)) + if (parseInt($('#thumbs_list_frame >li:visible').length) < parseInt($('#thumbs_list_frame >li').length)) $('#wrapResetImages').show('slow'); else $('#wrapResetImages').hide('slow'); @@ -559,7 +552,6 @@ $(document).ready(function() original_url = window.location + ''; first_url_check = true; - bigpicSrc = $('#bigpic').attr('src'); checkUrl(); initLocationChange(); diff --git a/themes/default/product.tpl b/themes/default/product.tpl index decb643cc..b7695b1e7 100644 --- a/themes/default/product.tpl +++ b/themes/default/product.tpl @@ -200,7 +200,7 @@ var fieldRequired = '{l s='Please fill in all the required fields before saving {foreach from=$images item=image name=thumbnails} {assign var=imageIds value="`$product->id`-`$image.id_image`"}
  • - + {$image.legend|htmlspecialchars}
  • @@ -540,7 +540,7 @@ var fieldRequired = '{l s='Please fill in all the required fields before saving {foreach from=$accessories item=accessory name=accessories_list} {if ($accessory.allow_oosp || $accessory.quantity_all_versions > 0) AND $accessory.available_for_order AND !isset($restricted_country_mode)} {assign var='accessoryLink' value=$link->getProductLink($accessory.id_product, $accessory.link_rewrite, $accessory.category)} -
  • +
  • {$accessory.name|escape:'htmlall':'UTF-8'} {if $accessory.show_price AND !isset($restricted_country_mode) AND !$PS_CATALOG_MODE} - {if $priceDisplay != 1}{displayWtPrice p=$accessory.price}{else}{displayWtPrice p=$accessory.price_tax_exc}{/if}{/if}