$user = wp_get_current_user();
if ( in_array( 'b2buser', (array) $user->roles ) ) {
// load the code to set minimum order quantities
}
Related Posts:
- WooCommerce – Reset quantity input field when variation changes
- Pass Category Name, Description and Photo into variables to pass to jQuery
- How can I get the values of my WordPress $wpdb query in Jquery?
- Hide payment method based on user role AND minimum cart value
- Woocommerce – if selected attribute term equals
- Replace the image of a product with its video in the shop page
- How to correctly add Javascript in functions.php
- Edit tag cloud widget number
- How to automatically apply woocommerce product title to all product images alt tags?
- Is it possible to get a theme customizer setting from wp.customize using jquery?
- How to get the original price of the product in woocommerce?
- Woocommerce auto cancel On-Hold after X days
- Hide a menu-item and its submenus and display a ‘Log in’ link if the user is logged out
- How to use WordPress (PHP) functions in AngularJS partials files?
- WooCommerce – Customer Order History Pagination
- Cleanest/Fastest way to avoid calling and retrieving data from the database multiple times?
- The values of custom fields are not available functions.php
- How can I loop into two different DIVS without repeating the DIVs
- Remove commas from WooCommerce checkout addresses fields
- WooCommerce – Display variation custom field value [closed]
- Output a WooCommerce product custom field in WooCommerce using get_post_meta()
- Woocommerce: Is it possible to overide the settings for allowing to purchase out of stock products [closed]
- Woocommerce HTML email option unavailable
- Click loads template via ajax
- How to add SVG icon above product tab title
- Use is_product_category() properly
- Changing Woocommerce flat rate every nth number of items
- Limiting woocommerce line_total decimal length
- How do I display a user’s previous orders as a select box option on a product?
- How do you add customer capability after Woocommerce purchase?
- combine Code 1 with Code 2
- get current product name in functions.php
- Image as Sales Badge
- jQuery not defined
- Conditional Header in wordpress
- Automatically remove a canceled order in Woocommerce
- Create another “Display Site Title and Tagline” checkbox, “Header Text Color” setting and control
- Two Different Links for Same Product – WooCommerce [closed]
- How can I apply_filters from inside a function?
- Auto-update products after they were published – Woocommerce
- Display a specific category of products in shop page and disable code for specific actions
- Woocommerce related product text
- Woocommerce: hook action/filter I could use to add variation id and price with each attribute opt on WooCommerce Rest api
- Ajax request not sending to server and returning – wp-admin/admin-ajax.php 400
- Is it possible to intercept all ajax requests and get the parameters and the returns?
- WooCommerce: How can I get orders with a custom ID in order meta data object?
- dynamic dependent select dropdown
- Change “add to cart” button color based on Woocommerce product category [closed]
- Ajax load more button for comments wordpress
- Incorrect amount of posts returned when filtering related Woo products by custom taxonomy
- Validation algorithm in checkout field
- My new button is in the wrong place
- How to disable controls in theme customizer?
- Add post with approval by the admin
- Function won’t run onclick using Ajax
- Theme not calling Jquery properly
- require_once() if a product in woocommerce contains a tag [closed]
- split 1 cart item into instock and back ordered
- AJAX to add to cart multiple products woocommerce
- Adding product permalink on admin order page throwing error
- Add Product Permalink in woocommerce admin order page
- How to override WooCommerce Order Item Meta with data from Cart?
- JQuery modal not loading video on popup, only displaying it after multiple reopenings
- Woocommerce textarea format ignored
- How to auto-generate random numbers in username?
- Remove generated category and tag class names from woocommerce product & blog listings markup
- WP_Query To Display Product Of Brand On Taxonomy Page
- Woocommerce Add custom “Add to cart button” in single page with tags
- How to echo a PHP code into WooCommerce variation product?
- Get Billing Email from WooCommece Checkout and Pass to Fullstory JS
- How to call a function from functions.php with ajax?
- Add another role to a user when they click a button?
- WordPress load javascript file if something… (after the page is loaded)
- How to properly create multiple conditions to redirect users roles to different pages
- Add missing alt tag to featured images for “storefront” theme
- How to call WordPress PHP file using external js file
- I was wondering if it’s possible to implement card.js on WordPress
- Find the method which AJAX GET calls
- Display text of price (minus 20%) on every product page in a sentence.
- jQuery doesn’t work in my php snippet
- Allow BBPress participant role to trash topics
- Use WP_Query Data In Cookie
- Extend the WP_Customize_Image_Control class to change its non-frame $button_labels
- A Customizer checkbox control that sets the setting to “” or to “blank” and show() or hide() a color control
- Woocommerce Price Text
- Get author meta of all writers
- Highlight posts currently being edited on multiple editor site?
- ajax form function error
- How to get the rating value of each comment
- Add specific phrase after every product title including the discounted price? [closed]
- How to add margin underneath woocommerce total price amount -> productpages
- AJAX: WordPress filters inside $html do not work as intended
- Setting WooCommerce currency programmatically
- Woocommerce – Shipping tax class based on cart items not using the highest tax available
- How to hide .js files on wordpress website using php or wp plugins or any? [closed]
- Warning: Attempt to read property “term_id” on int – Woocommerce
- WooCommerce – Show ‘Sales’ badge on variable products where only some variations have sales price [closed]
- posts_clauses drop ACF get_field function
- How to use js variable to php in wordpress functions.php
- Hide child of parent categories already hidden with “get_terms_args” – Woocommerce