Jump to content

How add more 1 pictures in product list?


KenFranklin

Recommended Posts

How add more 1 pictures in product list?

 

Part of product-list.tpl

<a class="product_img_link"    href="{$product.link|escape:'html':'UTF-8'}" title="{$product.name|escape:'html':'UTF-8'}" itemprop="url">
                            <img class="replace-2x img-responsive" src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home_default')|escape:'html':'UTF-8'}" alt="{if !empty($product.legend)}{$product.legend|escape:'html':'UTF-8'}{else}{$product.name|escape:'html':'UTF-8'}{/if}" title="{if !empty($product.legend)}{$product.legend|escape:'html':'UTF-8'}{else}{$product.name|escape:'html':'UTF-8'}{/if}" {if isset($homeSize)} width="{$homeSize.width}" height="{$homeSize.height}"{/if} itemprop="image" />
                        </a>

it is 1 picture.

1. how to make a loop for all pictures?

2. how to shop 2-3 pictures?

 

Link to comment
Share on other sites

Are you trying to show all the product images that are associated with a product in the product overview (category view) ? These images are probably (my first guess) not available there so you'd need to override the category view to grab the related images as well.

 

Let me know if this is right, I'll try and find this out for you (if someone doesn't know the answer right away)

Link to comment
Share on other sites

The product list page looks well with one image per product. I can imagine to add another one image but not more.

 

The product-list.tpl template is used by ProductController.php (initContent method) and more modules. You need to add the second image data to all of them.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...