Default Zoom for Product Variant Picures

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 лет назад
One of my biggest pet peeves is not being able to see a zoom/large graphic for every thumbnail on the page.  Here are the changes required to enable clickable zoomed pictures for product variants:



Add line to: NopCommerce\Presentation\Nop.Web\Controllers\CatalogController.cs
Function: PrepareProductVariantModel

  model.PictureModel.FullSizeImageUrl = _pictureService.GetPictureUrl(productVariant.PictureId);



replace section in: \NopCommerce\Presentation\Nop.Web\Views\Catalog\_ProductVariantLine.cshtml


    @if (!String.IsNullOrWhiteSpace(Model.PictureModel.ImageUrl))
    {
        <div class="picture">
            <a href="@Model.PictureModel.FullSizeImageUrl" rel="lightbox-p" title="@Model.Name">
                <img src="@Model.PictureModel.ImageUrl" alt="@Model.PictureModel.AlternateText"  title="@Model.PictureModel.Title" />
            </a>            
        </div>
    }


Can this functionality be enabled in v2.2 by any chance?  Maybe tied to Model.DefaultPictureZoomEnabled
or a new setting Model.DefaultVariantPictureZoomEnabled
12 лет назад
You saved my day…. Thanks
12 лет назад
Not sure when it was added, but it exists in 2.6.  You have to search for it in Admin > Configuration > Settings > All Settings (Advanced)
12 лет назад
I will be releasing code to the nopCommerce Team in the near future that will provide Zoom Lens support (by hovering over the main picture you will see a zoom lens and a zoom stage to the right), also hovering over product thumbnails will change the product main picture. On top of that, uploading product, manufacturer, and category pictures will name the pictures like so (product-name-1.jpg, product-name-2.jpg, category-name.jpg, manufacturer-name.jpg, etc) with the ability to specify your own picture name. I am going to submit it to Andrei for review within a couple weeks.
12 лет назад
Sounds very nice.

breakskater wrote:
I will be releasing code to the nopCommerce Team in the near future that will provide Zoom Lens support...


Does it use Flash though?
12 лет назад
SWW wrote:
Does it use Flash though?


No it does not use Flash. It uses jQuery and javascript.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.