Shopify themes, liquid, logos, and UX
this space is there only for products that are not on sale/do not have a discount. how do i get this space away?
Store Url: https://facce-amsterdam.nl/
This is Noah from PageFly - Shopify Page Builder App
Please add code here to fix it:
Step 1: Online Stores > Themes > Edit code
Step 2: Choose file theme.liquid
Step 3: Add code above the tag </head>
<script>
document.addEventListener(‘DOMContentLoaded’, function () {
setTimeout(function () {
const secondSpan = document.querySelector('.price__sale span:nth-child(2)');
const priceRegular = secondSpan.querySelector('s').textContent.trim();
if (priceRegular === '') {
secondSpan.style.display = 'none !important';
}
}, 1000);
});
</script>
Hope my solution will help you resolve the issue.
Best regards,
Noah | PageFly
Please let me know if it works by giving it a Like or marking it as a solution!
PageFly - #1 Page Builder for Shopify merchants.
All features are available from Free plan. Live Chat Support is available 24/7.
unfortunately it did not work
Hi @Svds please add code here again, Maybe symbol ' and ` in 'DOMContentLoaded' different:
<script>
document.addEventListener('DOMContentLoaded', function () {
setTimeout(function () {
const secondSpan = document.querySelector('.price__sale span:nth-child(2)');
const priceRegular = secondSpan.querySelector('s').textContent.trim();
if (priceRegular === '') {
secondSpan.style.display = 'none !important';
}
}, 1000);
});
</script>
Thank you !
Please let me know if it works by giving it a Like or marking it as a solution!
PageFly - #1 Page Builder for Shopify merchants.
All features are available from Free plan. Live Chat Support is available 24/7.
also didnt work unfortunately I do not know what the problem is
Hi @Svds I can explain to you the above code I wrote considering that if the value is empty, that part will be hidden. seems like an error occurred. Let me check further
Please let me know if it works by giving it a Like or marking it as a solution!
PageFly - #1 Page Builder for Shopify merchants.
All features are available from Free plan. Live Chat Support is available 24/7.
@Svds
Hi
Which theme have you used currently for your website?
I think there is the option to remove that space in the theme customization, in the theme customize option go to product page and check all option
Thanks
i dont think there is a theme customization for this since this is not the case for products that are on sale, it is a issue that needs to be coded i think. my theme is refresh
Hi @Svds
You can try the following steps:
Step 1: Go to Admin -> Online store -> Theme > Edit code:
Step 2: Search for base.css
Step 3: Add this code at the end of the file
.product__info-wrapper .price__sale { flex-direction: row!important }
You will get the result like this:
B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.
B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.
B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.
BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now
Hi @Svds
You can try the following steps:
Step 1: Go to Admin -> Online store -> Theme > Edit code:
Step 2: Search for base.css
Step 3: Add this code at the end of the file
.product__info-wrapper .price__sale { flex-direction: row!important }
You will get the result like this:
I hope this helps! If it works for you, please mark it as a solution. I am very happy about that. Have a great day!
B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.
B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.
B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.
BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now
Hi @Svds
You can try the following steps:
Step 1: Go to Admin -> Online store -> Theme > Edit code:
Step 2: Search for base.css.
Step 3: Add this code at the end of the file.
.product__info-wrapper .price__sale { flex-direction: row!important }
You will get the result like this:
I hope this helps! If it works for you, please mark it as a solution. I am very happy about that. Have a great day!
B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.
B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.
B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.
BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now
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