Woocommerce has two button types in the product loop
- “add to cart” for adding simple products to cart
- “select options” if a simple product becomes a variable one or a subscription option is added.
My setting:
All Woocommerce products are configured as simple products and subscription products at the same time using the following plugins
- “Woocommerce Subscription”
- “All Products for Woocommerce Subscription”. Default is set to simple product.
Now the buttons on all products change from “add to cart” to “select options”. That is Woocommerce default behavior.
My Question:
How can I keep the “add to cart” button and its functionality of adding the simple product to cart despite having a variable product?
Logic behind it: Users are given the opportunity to make a choice on checkout and therefore add to cart functionality instead of redirect to single product page for making a choice is desired.
2
Answers
You could use: (Explanation via comment tags added in the code)