Tag: Wordpress
-
How to split woocommerce order notification emails among different admin recipients based on the product purchased?
To split WooCommerce order notification emails among different admin recipients based on the product purchased, you can follow these steps: Guys if you are new in WordPress or in WooCommerce then please check the below links for some good tutorials: 1. Identify Email Recipients Determine who needs to receive the notification emails for specific products.…
Written by
-
WooCommerce Set Minimum Order Amount based on cities
To set a minimum order amount based on cities in WooCommerce, you’ll need to add some custom code to your site. This typically involves writing a function in PHP that checks the customer’s shipping city during the checkout process and sets a minimum order amount accordingly. Here’s a step-by-step guide on how you can implement…
Written by
-
How to display Primary Category in the WordPress Permalink?
To display the primary category in the permalink of your WordPress posts, you’ll need to modify the permalink structure to include the category. This involves a bit of setup and customization within your WordPress site. Here’s how you can do it: 1. Set the Permalink Structure First, you need to adjust the permalink settings to…
Written by
-
How to create custom fields in WooCommerce checkout form?
Creating custom fields in the checkout process of a WooCommerce store can enhance the user experience by collecting additional, relevant information from customers. Here’s a step-by-step guide on how to do this using hooks in WooCommerce, without a plugin. If you prefer a plugin, I can guide you through that process as well. Step 1:…
Written by
-
How to offer shipping on products but local pickup only in WooCommerce?
Setting up different delivery options for specific products in WooCommerce involves using conditional logic to control shipping methods based on the products in the cart. Here’s a step-by-step guide on how to offer shipping for one product and local pickup only for another within WooCommerce: Step 1: Set Up Shipping Zones First, you need to…
Written by
-
Implementing product visibility based on user role along with time scheduling in WooCommerce
Implementing product visibility based on user role along with time scheduling in WooCommerce involves customizing how and when products are displayed to different user roles on your WordPress site. You’ll need to use hooks and filters provided by WooCommerce and possibly some custom programming to manage the visibility of products based on both the user’s…
Written by
-
How to add a 20% increase to the product pricing in WooCommerce?
To add a 20% increase to the product pricing in WooCommerce, you can use a hook in your theme’s functions.php file or in a custom plugin. This involves manipulating the price display using WooCommerce hooks, particularly focusing on altering the product prices dynamically. Here’s how you can achieve this by adding a snippet of PHP…
Written by
-
Exclude a specific shipping class from qualifying for free shipping in WooCommerce
woocommerce free shipping exclude for some classes, Hide other shipping methods when “Free Shipping” is available, Hide free shipping for specific shipping classes exclusively in Woocommerce. To exclude a specific shipping class, such as one for bulky items, from qualifying for free shipping in WooCommerce, you can modify the settings for the free shipping method.…
Written by
-
Woocommerce apply coupon programmatically on cheapest product in cart
Apply Coupon Programmatically woocommerce, WooCommerce before apply coupon hook, Woocommerce apply coupon ajax, WooCommerce add discount to cart programmatically, Woocommerce apply coupon programmatically on cheapest product in cart code To programmatically apply a coupon to the cheapest product in the cart in a WooCommerce store, you can achieve this by using WooCommerce hooks and custom…
Written by
-
How to get current logged in user using WordPress Rest Api?
Woocommerce, Woocommerce Hooks, Wordpress, Wordpress Cheat Codes, Wordpress Hooks, wordpress rest api, Wordpress TricksHello guys, how are you? Welcome back on blog therichpost.com. To obtain information about the current logged-in user through the WordPress REST API, please follow the below logic guys. $user_id = “”; //<- add this add_action( ‘rest_api_init’, ‘add_custom_users_api’); function add_custom_users_api(){ $GLOBALS[‘user_id’] = get_current_user_id(); //<- add this // route url: domain.com/wp-json/mmw/v1/testing register_rest_route( ‘mmw/v1’, ‘testing’, array( ‘methods’…
Written by