0

Remove the slider and show gallery image as thumbnails on the detail page Magento 2.

please anyone can help me how can I solve this??

0

You can set the template using layout XML, then make any customizations you want within that file:

In app/design/frontend/[Vendor]/[Module]/Magento_Catalog/layout/catalog_product_view.xml, add the following within the <body> tag:

    <referenceBlock name="product.info.media.image">
            <action method="setTemplate">
                    <argument name="template" xsi:type="string">path/to/your/template.phtml</argument>
            </action>
    </referenceBlock>

In this case, you will create a file in app/design/frontend/[Vendor]/[Module]/Magento_Catalog/templates/path/to/your/template.phtml. If you want to start with the native-magento template, you can copy the contents of vendor/magento/module-catalog/view/frontend/templates/product/view/gallery.phtml into your new template-file. This would give your a good starting point, but either way, you should be able create the desired output.

  • hey, thanks for your answer but I am new in Magento 2 so can you guide me how can I make like this. awesomescreenshot.com/image/3334108/… – Jigar Panchal May 3 '18 at 13:07
  • This article will help you create a theme. For this case, the only required parts are the registration.php and theme.xml. Once you have a theme, you should be able to follow the instructions in my answer. – mtr.web May 3 '18 at 13:11
  • I have created a custom theme and I have overridden gallery.phtml but I need the design like this. i have a copy this file and put it on that on my theme. – Jigar Panchal May 3 '18 at 13:14
  • There are probably a dozen different ways that you could get your gallery to look that way. Add a custom css/less file to your theme, and start experimenting.. – mtr.web May 3 '18 at 13:17
  • Also, if you are basing your design on an existing one, go to the site from your screenshot, right click the gallery and click inspect. That should give you an idea of the css that is used and how you can recreate it. – mtr.web May 3 '18 at 13:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.