All things Shopify and commerce
My product image on my product theme layout page keeps moving when i scroll down to my description. I want it as a slide show where you can flick through my product images with the description below.
If you're comfortable with coding or have a developer, you can modify the theme code to implement a slideshow manually.
Find the Product Template:
Include a Slideshow Library: Use a JavaScript library like Flickity or Swiper.js to create a responsive slideshow.
Modify the Product Image Section: Replace the current image layout with a slideshow container. For example:
<div class="product-gallery">
<div class="gallery-slider">
{% for image in product.images %}
<div class="gallery-slide">
<img src="{{ image | img_url: '1024x1024' }}" alt="{{ image.alt }}">
</div>
{% endfor %}
</div>
</div>
Add Styles and Scripts: Include the necessary CSS and JS for the slideshow in your theme's theme.liquid file:
<!-- Include Flickity -->
<link rel="stylesheet" href="https://unpkg.com/flickity@2/dist/flickity.min.css">
<script src="https://unpkg.com/flickity@2/dist/flickity.pkgd.min.js"></script>
<script>
document.addEventListener('DOMContentLoaded', function () {
var elem = document.querySelector('.gallery-slider');
var flkty = new Flickity(elem, {
cellAlign: 'center',
contain: true,
wrapAround: true
});
});
</script>
Ensure Description Placement: Ensure the product description is below the slideshow in the HTML structure:
html
<div class="product-description">
{{ product.description }}
</div>
Need any help:
Contact: info@webcraftio.com orWhatsapp +442071936499
Hi,
This is Richard at PageFly - Shopify Advanced Page Builder app.
1. Understand the Issue:
2. Solutions:
Theme Customization (Recommended for those comfortable with coding):
Hoping my solution helps you solve your problem.
Best regards,
Richard | PageFly
Please let me know if it works by giving it a Like or marking it as a solution!
➜ Optimize your Shopify store with PageFly Page Builder (Free plan available)
All features are available from Free plan. Live Chat Support is available 24/7.
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024