Home › Forums › WoodMart support forum › Remove “Clear”, Quantity, Add to cart
Remove “Clear”, Quantity, Add to cart
- This topic has 6 replies, 2 voices, and was last updated 2 months ago by Hung Pham.
-
AuthorPosts
-
September 22, 2024 at 12:05 am #599139
amirghaffarii03ParticipantHello,
We would need help with the following on the Add to cart widget.1. Remove the Clear text and function/animation when you chose a variation.
2. Have a preselected variation, so instead of none of the varition being selected from the start we can choose which variation to be the defult selected once you load in.
3. Add code to remove the Add to cart button, as there are no other widget where we can access the variation without adding the add to cart.
4. Removing the Quantity Button.
Attachments:
You must be logged in to view attached files.September 22, 2024 at 12:09 am #599141
amirghaffarii03ParticipantI also want to mention we did try to remove the clear button with
“add_filter(“woocommerce_reset_variations_link”, “__return_false” );”
However the animation is still there, the cart button moves slighlty after we select a variation.
September 23, 2024 at 3:40 pm #599432
Hung PhamKeymasterHello amirghaffarii03,
Thanks for reaching to us.
First of all, I am appreciate your patience.
1. Please try adding the following Custom CSS in the Global Custom CSS area under Theme Settings > Custom CSS.
.variations_form.variation-swatch-selected .reset_variations { display:none; }
2. To achieve this, you can use the “
Default Form Values
option on the “Variations” tab in your WooCommerce settings. This will allow you to set the first variation as the default selection on the product page.
https://snipboard.io/0TA2v9.jpg3. Navigate to Theme Settings > Shop > turn on the
Enable catalog mode
option https://take.ms/k5Ls14. There are 2 points regarding that:
+ If you want to remove quantities box, it does mean you want to sell 1 item for each product only, so keep it in the Cart page doesn’t make sense. If it’s true, then I kindly request that you enable the option to be Sold Individually, which will remove the quantity selection from specific single product and Cart page as well https://prnt.sc/dnAHNuPDlOet
+ In case you are simply want to remove it from all products, add below Custom CSS code to Theme Settings > Custom CSS > Global custom CSS
.single-product .quantity{ display: none; }
Regards,
September 23, 2024 at 9:03 pm #599518
amirghaffarii03ParticipantHey,
1. I did try this and it does not work. We are currently using Code Snippets and tried with this code and it works, but please look if you can find a way to change this without us needing to add another plugin such as Code Snippets.
“add_filter(“woocommerce_reset_variations_link”, “__return_false” );”2. Got it, thank you
3. When enabling catalog mode the variants gets removed, which is not what we want, it it possible to enable catalog mod without the variants to ge removed?
4. Okay I will try this, thanks
September 24, 2024 at 8:16 am #599559
Hung PhamKeymasterHello amirghaffarii03,
1. Try to add the following code in the function.php of the child theme.
add_filter('woocommerce_reset_variations_link', '__return_empty_string');
3. If you removed Add to cart button then it doesn’t make sense to let your customers to select variations. Can you please describe in more details?
Regards,
September 24, 2024 at 3:45 pm #599741
amirghaffarii03ParticipantHello,
Well we want the customer to be able to see the different variants and prices, when adding the catalog mode, the variation options are removed, so the customer cant see the different varins that we offer.Why we want to remove the cart, is because we dont want them to checkout, instead we want them to join the waitlist that we have
September 25, 2024 at 10:52 am #599927
Hung PhamKeymasterHi amirghaffarii03,
WoodMart theme does not have the option to control that.
For specialized assistance and potential solutions, I kindly suggest that you reach out directly to the WooCommerce plugin’s support team https://wordpress.org/support/plugin/woocommerce/, who are better equipped to provide you with the guidance you requires or You need to find a third party plugin to achieve more functionality that best suits you.
If you have any questions please feel free to contact us.
Regards,
-
AuthorPosts
Tagged: single product page
- You must be logged in to create new topics. Login / Register