Hello! I need a code to hide the price, stock and add to cart button throughout the website for certain specific products by ID.
This topic has 10 replies, 3 voices, and was last updated 1 weeks, 1 days ago ago by Luca Rossi
Hello! I need a code to hide the price, stock and add to cart button throughout the website for certain specific products by ID.
Hello!
Thank you for reaching out to us.
To hide the price, stock, and Add to Cart button for specific products by their ID across your website, you can use the following custom CSS code:
.postid-24732 .et_product-block > .price,
.postid-24732 .stock,
.postid-24732 .single-product-builder form.cart {
display: none;
}
Best Regards,
8Theme’s Team
Hello! These codes only hide from single product but do not hide it from the store catalog.
I need the code to hide all those specific product buttons throughout the site, as I want the only way they can order the product is through a private email.
In the private area I leave access to the test site where I am testing the idea.
It will be a specific product category that can only be purchased on demand, so all those buttons must be hidden.
Dear @LVRB,
We hope this message finds you well.
Could you please add the following custom CSS code to your site?
.postid-24732 .product-details .price,
.postid-24732 .product-details .quantity-wrapper {
display: none !important;
}
Kindly let us know once it has been implemented or if you encounter any issues.
Best regards,
The 8Theme Team
Hello!
The code has already been applied on the test website and does not hide the price, variations and add to cart of the specific product from the catalog.
Please help me with the problem.
Attached screenshot in private message.
Dear @LVRB,
We hope this message finds you well.
We would like to inform you that the previous custom code contained an error. Our team has corrected the issue and updated the custom CSS on your website with the following code:
.post-2911 .product-details .price,
.post-2911 .product-details .quantity-wrapper,
.post-2911 .product-details form.cart {
display: none !important;
}
Could you please review the changes at your earliest convenience and let us know if everything is now working as expected?
Thank you for your attention to this matter.
Best regards,
The 8Theme Team
This code does work!
Can you send me a code to hide the variation swatches in the catalog please?
Thank you!
Hi @LVRB,
Please update the previous CSS code to this:
.post-2911 .product-details .price,
.post-2911 .product-details .quantity-wrapper,
.post-2911 .product-details .st-swatch-in-loop,
.post-2911 .product-details form.cart {
display: none !important;
}
Hope it helps!
THANKS!
I need a code to hide sales booster item sold fake indicator for specific products please.
Capture attached.
🙂
Hi @LVRB,
The custom CSS code will look like this:
body.postid-2806 p.sales-booster-total-sales {
display: none !important;
}
Hope it helps!
You must be logged in to reply to this topic.Log in/Sign up