All things Shopify and commerce
Hi, I found a few apps that have before-and-after slide, however it applies to all product pages.
I want to make separate before-and-after slide for each product page.
How can I do that?
Hi @lenssis2025
Please check if the app can apply slides to selected products. If it does not, I guess you will need to create a separate product template for each product and then add a separate slide to them.
You can check this to learn how to create a separate product template.
https://help.shopify.com/en/manual/online-store/themes/theme-structure/templates
Best regards,
Dan
- Found this helpful? Hit "Like" and "Accept as Solution"! Support me: Donate!
- Reton: Loyalty & Rewards - Earn points through tasks, redeem for discounts, and enjoy exclusive VIP rewards!
- Ryviu - Reviews & QA app: Collect product reviews, import reviews from AliExpress, Amazon, Etsy, Walmart, Shopee, Dhgate and CSV.
- Lookfy Gallery: Lookbook Image - Gain customers with photo gallery, video & shoppable image
Built for Shopify
Reelfy‑Shoppable Videos+Reels: Create shoppable videos to engage customers and drive more sales.
- En...Sign up now.
Hi @lenssis2025 ,
To create a before-and-after slider specific to each product page in Shopify:
Using Metafields
Add Metafields
Edit Theme Code
{% if product.metafields.custom.before_image and product.metafields.custom.after_image %}
<div class="before-after-slider">
<div class="before" style="background-image: url('{{ product.metafields.custom.before_image | img_url: 'large' }}');"></div>
<div class="after" style="background-image: url('{{ product.metafields.custom.after_image | img_url: 'large' }}');"></div>
<input type="range" min="0" max="100" value="50" class="slider">
</div>
<script>
document.querySelector(".slider").addEventListener("input", function () {
document.querySelector(".after").style.clipPath = `inset(0 ${100 - this.value}% 0 0)`;
});
</script>
{% endif %}
3.Save & Check – Each product will display its own unique before-and-after slider.
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025