Adding an action in WooCommerce is simple. You just need to find the WooCommerce tab in your WordPress admin panel, and then click on Actions.
From there, you can either add a new action by clicking on the Add New Action button, or edit an existing action by clicking on its name.
Once you’re on the Add New Action page, you’ll need to enter a name for your action and then select the type of action it is. There are four types of actions:
- Simple Action: A simple action is one that doesn’t require any extra information from the customer. For example, if you want to offer a discount to customers who purchase over a certain amount, you would select the Simple Action type.
- Variable Action: A variable action is one that requires extra information from the customer in order to be processed. For example, if you want to offer a discount to customers who purchase a specific product, you would select the Variable Action. You would then need to enter the product ID in the Product ID field.Grouped Action: A grouped action is one that applies to a group of products, rather than a single product.
For example, if you want to offer a discount to customers who purchase any products in a certain category, you would select the Grouped Action. You would then need to enter the category ID in the Category ID. field.Cart Contents Action:: A cart contents action is one that applies to all products in the cart, regardless of their individual settings. For example, if you want to offer a free shipping discount to customers who purchase over a certain amount, you would select the Cart Contents Action. You would then need to enter the minimum order amount in the “Free Shipping Minimum Order Amount” field.“Add to Cart”: The action will be triggered when the customer adds a product to their cart.“Purchase”: The action will be triggered when the customer completes their purchase.“Both”: The action will be triggered when the customer either adds a product to their cart or completes their purchase.“Percentage Discount”: The discount will be applied as a percentage off of each product’s price.
“Fixed Discount”/d> : The discount will be applied as a fixed amount off of each product’s price.“Fixed Price”/d>The price of each product will be set to a fixed amount. /ul18 After l19 u=””>you’ve selected what kind of discount it should be, you’ll need enter how much l20 u=””>the discount should be. For example, if you’re offering a 10% l21 u=””>discount, you would enter “10” in the “Discount Amount” field./l22 u=””> /p23 Adding an action in WooCommerce is simple and only requires a few clicks. After finding the WooCommerce tab in your WordPress admin panel and selecting Actions, click Add New Action or edit an existing action. Then fill out basic information such as name and type before selecting when it should be triggered and what kind of discount it should apply.
PRO TIP: If you are not familiar with code or are not comfortable working with code, we recommend that you seek help from a developer before attempting to add an action in WooCommerce. Adding an action in WooCommerce can be tricky and if not done correctly, could break your site.