All things Shopify and commerce
HI, I'm setting up a POD store and some of my designs have both side of the apparel printed on. How do i make it such that, should the product be selected from the catalogue, the customer is able to scroll between both the front and back sides of the design? Like an arrow at the bottom of the product image to show the customer the design on the other side?
Hi,
Prepare your image first after that
Use HTML for the Toggle Feature (at templates/product.liquid or sections/product-template.liquid)
Code example
<div class="product-image-slider">
<div class="image-container">
<img id="product-image" src="{{ 'front-design.jpg' | asset_url }}" alt="Product Design">
</div>
<div class="toggle-buttons">
<button class="toggle-front" onclick="showFront()">Front</button>
<button class="toggle-back" onclick="showBack()">Back</button>
</div>
</div>
Use CSS for Styling
Use Javascript Toggle Functionality
Javascript example
function showFront() {
document.getElementById('product-image').src='{{ 'front-design.jpg' | asset_url }}';
}
function showBack() {
document.getElementById('product-image').src='{{ 'back-design.jpg' | asset_url }}';
}
Discover how to increase customer engagement on your store with articles from Shopify A...
By Jacqui Apr 23, 2025Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025