Product Template - Remove Images

Is there a code snippet that can remove product images from a defined product template?

Previously we used:


Which removes the product images at the site wide level, I want to be able to display products on defined template now however. Can this be modified to accommodate?

Hey @theworldfamous

Follow these Steps:

  1. Go to Online Store

  2. Edit Code

  3. Find theme.liquid file

  4. Add the following code in the bottom of the file above tag

{% if template == 'your-template' %}

{% endif %}

NOTE: Replace “your-template” with the name of your template and it should be good.

If I managed to help you then, don’t forget to Like it and Mark it as Solution!

Best Regards,
Moeed

This line of code works, is it able to work on multiple product themes I apply it to? I wrote it like this in the example for the two templates I want to show no product images, however it fails.


          {% if template == 'product.drug-testing' and 'product.dna-testing' %}
          

{% endif %}

Hey @theworldfamous

You can try this code instead

{% if template == 'product.drug-testing'%}        

{% endif %}
{% if template == 'product.dna-testing'%}        

{% endif %}

If I managed to help you then, don’t forget to Like it and Mark it as Solution!

Best Regards,
Moeed