Category: Woocommerce Hooks
-
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
-
Woocommerce Instagram shop for vendors
If you’re looking to set up an Instagram shop for vendors on a WooCommerce Dokan website, there are a few steps you’ll need to follow. This integration allows you to feature and sell products directly through Instagram, making it easier for customers to shop your items right from their feeds. Here’s how you can get…
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
-
Woocommerce hook change shipping text on checkout page
Hello guys how are you? Welcome back to my channel. Today in this post I am going to show you Woocommerce hook change shipping text on checkout page. Guys I have used both latest versions WordPress 6.3 and WooCommerce 8.6. Guys if you are new in WordPress or in WooCommerce then please check the below links…
Written by
-
How to Move coupon form before subtotal in WooCommerce checkout after ajax?
To move the coupon form before the subtotal in the WooCommerce checkout page, especially after an AJAX update (which occurs when cart items are updated), you’ll need to use a combination of actions and filters provided by WooCommerce, as well as some custom JavaScript to handle the AJAX event. Step 1: Remove the Default Coupon…
Written by
-
How to reorder checkout fields in WooCommerce 8+?
Hello guys how are you? Welcome back to my channel. Today in this post I am going to show you How to reorder checkout fields in WooCommerce 8+? Guys I have used both latest versions WordPress 6.3 and WooCommerce 8.6. Guys if you are new in WordPress or in WooCommerce then please check the below links…
Written by