Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hello,
I have a pastry category that displays items. Some of them can be ordered online, so they display the price. Other cannot be ordered online, so they should not display the price. I have created a product template with a hidden price for those particular items. The problem is that the category template displays the price and not the product template. My question is, how may I hide the price for only certain products in the same category template. It can probably be achieve with css, but I am not sure how to target specific products.
In the screeshot, the price for the Lemon Meringue Tartelette should be hidden.
Share url
https://patisserie-lasalle.myshopify.com/
pass : ilovecake
It's in the pastry section
Hey Saeed,
Thank you for your reply.
I understand what to do, however, I do not seem to have any "Additional CSS classes" field under the "Advanced" section when editing a product so that I can add a class.
Yes exactly!
And in which file should I add the code you provided?
No worries Saeed, thank you so much for your precious time! Have a great one!
go to main-collection-product-grid.liquid and just remove the product price code
Actually I fixed it by adding a tag to products that don't display the price and set that tag to hid price this way all other products are not affected.
thank you for the help!
Hi!
I've been looking for the same solution for a long time.
Could you please share the code you added, and where you added it!?
Thanks so much in advance.
2m ago Learn the essential skills to navigate the Shopify admin with confidence. T...
By Shopify Feb 12, 2025Learn how to expand your operations internationally with Shopify Academy’s learning path...
By Shopify Feb 4, 2025Hey Community, happy February! Looking back to January, we kicked off the year with 8....
By JasonH Feb 3, 2025