Shopify themes, liquid, logos, and UX
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Hi,
I'm looking for a solution to remove the prices on the featured collection on the homepage ONLY. I've tried a lot of different options but it doesn't work or the lines of code to modify don't exist or it removes the prices everywhere.
If there is any option to remove all the prices on the homepage that would work as well.
I'm using the theme dawn 9.0.0
Does anyone knows how to do it?
Here is my website.
514rpm.com
Thank you!
Solved! Go to the solution
This is an accepted solution.
Simply remove remove the first line of the css, as below then.
<style>
body.index .price {
display: none !important;
}
</style>
Thank you for you reply,
I treid what you said but the line of code ''<span class="price">{{ product.price | money }}</span>''
doesn't exist. Here is what I have arround where it is suppose to be I believe.
{%- if show_mobile_slider or show_desktop_slider -%}
<div class="slider-buttons no-js-hidden">
<button
type="button"
class="slider-button slider-button--prev"
name="previous"
aria-label="{{ 'general.slider.previous_slide' | t }}"
aria-controls="Slider-{{ section.id }}"
>
{% render 'icon-caret' %}
</button>
<div class="slider-counter caption">
<span class="slider-counter--current">1</span>
<span aria-hidden="true"> / </span>
<span class="visually-hidden">{{ 'general.slider.of' | t }}</span>
<span class="slider-counter--total">{{ products_to_display }}</span>
</div>
<button
type="button"
class="slider-button slider-button--next"
name="next"
aria-label="{{ 'general.slider.next_slide' | t }}"
aria-controls="Slider-{{ section.id }}"
Do you have any other idea?
Do you know what to do?
Hi @514rpm ,
<style>
body.index .price,
body.collection .price {
display: none;
}
</style>
Thanks for helping me,
It worked for the homepage but also in the collections but I need the prices to be seen into the collections.
What I'm looking for is to have no prices on the homepage only. Do you know how to do it?
This is an accepted solution.
Simply remove remove the first line of the css, as below then.
<style>
body.index .price {
display: none !important;
}
</style>
It worked, that's awesome! Thank you!
Hi Kat, I'm dealing with the same issue and would like some clarity. When you say remove the first line of the css, what line are you referring to? Is it the first line of component-price.css?
Hi@jlovelace1
That was in reference to the first code solution I shared, this is the version you should use.
<style>
body.index .price {
display: none !important;
}
</style>
This should go at the bottom of your "Layouts/theme.liquid" file, just above </body>
Okay. I tried this, nothing changed for me.
Hi,
Since the last update 11.0.0 it doesn`t work anymore. Do you know what I can to fix it?
Thank you so much!
Hi Kat,
I also have the same issue.
Can you please look into it? My website is https://castillajewelry.com/
The passcode is 430Athra.
Thank you.
Hi @514rpm
I hope you are doing good and welcome to the Shopify Community!
I am San from MS Web Designer.
1st you need to replace <body class="gradient"> to <body class="template-{{ request.page_type | handle }} gradient"> in your theme.liquid page.
2nd put this css in your bottom of the base.css file:
.template-index .price {display: none !important;}
Regards,
San
If it’s helpful to you, please mark it as a solution.
Need Help with Shopify Design, Migration, Speed, or Custom tasks?
email: hi@mswebdesigner.com
Try Our Conversion Booster app to get more sales | Connect Our Founder Linkedin
T tried but it did nothing unless I did something wrong, could you detail more the steps maybe?