All things Shopify and commerce
Hi, I'm using the 'Impulse' theme. I would like to show the featured image (first image) rather than the image of the first variant when the page is initially loaded. So when the user clicks on the item to get to the product page, main product image to stay until the user selects a variant. Please help.
Impulse is made by archetypethemes , and is a premium theme meaning most contributors don't have access to it's code like they would with a free theme.
Contact archetypethemes to see if they support this customization here https://archetypethemes.co/pages/support
Save time & money ,Ask Questions The Smart Way
Confused? Busy? Get the solution you need paull.newton+shopifyforum@gmail.com
Problem Solved? ✔Accept and Like solutions to help future merchants
Answers powered by coffee Buy Paul a ☕ Coffee for more answers or donate to eff.org
Thank you.
Have a good day:)
Hi Boram,
You need to change code in liquid file, find liquid file where product information render (mostly used product-template.liquid).
replace the code with:
{% assign featured_image = product.selected_or_first_available_variant.featured_image | default: product.featured_image %}
Try changing it to:
{% assign featured_image = product.featured_image %}
Thank you so much.
Always welcome 🙂
This worked! Thank you!
Any chance you can point out the liquid file you modified with this code? Thank you
Hey, i have tried to find that code on the impulse 7.1 version and i didnt find it. can you help please?
@ksh_verma Hey! this is the code on Impluse 7.1
i cant find the code u suggested to change. can you please assist?
{%- liquid
assign current_variant = product.selected_or_first_available_variant
unless thumbnail_position
assign thumbnail_position = 'beside'
endunless
assign product_zoom_size = '1800x1800'
assign product_image_size = '620x'
case image_container_width
when 'small'
assign product_image_width = 'medium-up--two-fifths'
assign product_description_width = 'medium-up--three-fifths'
assign product_image_size = '480x'
when 'medium'
assign product_image_width = 'medium-up--one-half'
assign product_description_width = 'medium-up--one-half'
assign product_image_size = '620x'
when 'large'
assign product_image_width = 'medium-up--three-fifths'
assign product_description_width = 'medium-up--two-fifths'
assign product_image_size = '740x'
endcase
assign product_img_structure = product.featured_media | img_url: '1x1' | replace: '_1x1.', '_{width}x.'
-%}
Hi there, found any solution for this?
Are you ready to take your business to the next level? Look no further than the latest ...
By SarahF_Shopify Apr 15, 2024We’re keeping the ball rolling to make sure you’re always ahead of the game. So buckle ...
By JasonH Apr 8, 2024Portrait of Stephen positioned next to an image of planet Earth, with the Stephen's World ...
By JasonH Mar 18, 2024