You can create a helper function for that which qurries the orders for given email and created less than 10 mins ago.
function wpse407278_check_if_ordered_in_last_10_mins( $email ) {
if ( !isset($email) || empty($email) ) {
return false;
}
$args = array(
'customer' => $email,
'date_created' => '>' . ( time() - strtotime('-10 minutes') ),
);
$orders = wc_get_orders( $args );
if ( empty( $orders ) ) {
return false;
}
return true;
}
This will return true if the customer has orderd within last 10 minutes and false otherwise.
Related Posts:
- Username field is not shown in Woocommerce’s registration contact form
- Custom Redirect after registration in WooCommerce
- Which hook should I use to capture $_POST(‘password’) via profile update and password reset
- Force User Registration before visitng Checkout Page
- Register a new user on wooCommerce using Rest API
- Allow WooCommerce existing customers to checkout without being logged in [closed]
- WooCommerce: “account is already registered with your email address”
- Auto generate user email while registration
- Sender e-mail address, for new order email to customer, is suddenly wrong [closed]
- WooCommerce Registration redirect based on page ID
- Block Disposable Emails on Woocommerce Registration
- Clients with empty username are not receiving request new password email
- Woocommerce Register Error
- Make e-Mail optional on Woocommerce sign up
- Assign user role by text field in WordPress (Woocommerce) [closed]
- Impossible to create a new WooCommerce customer using Rest API
- Registration roles
- How to send Woocommerce Customer Details (Name, Email and Phone Number) to Admin upon signup
- Redirect After Registration on Specific Link
- Custom Registration Fields woocommerce
- Allow users to register on multisite through WooCommerce using the same email address
- Change WooCommerce registration form/way?
- DatePicker in Woocommerce (My Account) Registration [closed]
- Remove login fields from /customer-account page [closed]
- My account page, don’t show the complete “Registration form”
- How can I be certain that a user has verified their email after registration?
- WooCommerce: Can’t use wc_get_products for custom REST API endpoints
- How to remove an action within a class with extends
- wc_get_template_part( ‘content’, ‘product’ ) | Where is this file located?
- how to get woocommerce product attribute slug
- How to disable Woocommerce password recovery and use the default WordPress password reset page?
- Limit users to one active subscription in WooCommerce Subscriptions? [closed]
- How to build a plugin that supports authenticated POST requests to the REST API from external servers?
- Display WooCommerce size product attribute on shop page
- Create WooCommerce custom stock option that is non-purchasable
- Query multiple post type and categories
- Shipping restrictions with WooCommerce variable products
- WooCommerce – Flat rate shipping based on X quantity steps?
- WooCommerce add_to_cart() with custom price [closed]
- Declaring custom woocommerce product type as virtual / downloadable only [closed]
- How to remove_action inside class [duplicate]
- Redirect if current user is logged out and current page is /my-account
- woocommerce_before_calculate_totals in woocommerce 3.0
- Custom URL for each product variation – rewrite rules
- Where can I find a single item template
- Get Woocommerce Subscription Product
- WooCommerce HTML after short description if product is in specific category
- How to get total count for each star rating?
- Change “Shipping” text to “Delivery” everywhere I appears in woocommerce
- Customize WooCommerce orders displayed shipping
- WooCommerce pages accessible to logged in members only
- Display a list subcategories under the main product category thumbnails?
- Unable to programmatically remove product from WooCommerce cart
- creating product with variations using woocommerce REST API
- WooCommerce Apply Coupon to order AFTER taxes
- Rewriting Woocommerce Product Filters To URL Segments
- How to Change WooCommerce Variable product pricing by SKU or visible children id
- Is it possible to cache ?wc-ajax=get_variation
- Adding extra one email address who receives email as admin – woocommerce
- Woocomerce language
- echo product id and product_item_key in cart [closed]
- Redirect the single product page link to the shop page
- Is WooCommerce updates for WordPress necessary? [closed]
- How to set default values in Woocommerce checkout? [closed]
- How can I display *only* the child category of a product?
- paypal not showing on woocommerce payments
- Target WooCommerce Product Gallery Image (rather than Featured Image) for og:image
- How to implement Handling Fee like the Shipping on Cart and Checkout page on WooCommerce [closed]
- why featured product not updated in postmeta table in woocommerce?
- Display list of categories that contain products with a specific tag
- Payment methods are not displaying in Woocommerce
- How to update the WooCommerce cart Icon to show new products added with JavaScript
- wooCommerce checkout page State / County (optional) validate not working
- How to display empty stars on products with woocommerce?
- Remove the link from the thumbnail and product title on woocommerce
- Product admin page breaking with too many product variations [closed]
- How to configure Woocommerce Payment Methods programmatically?
- woocommerce_package_rates not fired everytime
- how to change woocommerce shop archive description? [closed]
- WooCommerce limited role
- Skip WooCommerce 4.5.x onboarding with WP-CLI [closed]
- Add content to the last slide of each product
- Remove add to cart icon/view product button woocommerce
- Products Shortcode is Displaying Single Product Page Price for all Products [closed]
- Subscription on Checkout
- Woocommerce – display product in page but in list format with excerpt
- how to show store name when I add a product on cart in woocommerce(woocommerce multi store)?
- When Free shipping is available hide other shipping methods except Local pickup in WooCommerce [closed]
- Automatically making a newly saved payment method default in WooCommerce
- WooCommerce update_shipping_method ajax call wipes shipping method set on non-checkout page [closed]
- Product options/variations notice displays as an Alert [closed]
- Expired session error (admin) when I try to make a call to WooCommerce api [closed]
- Create archive page for woocommerce attribute
- Display FREE for $0 products in woocommerce ++++ [closed]
- How to add existing categories into a post using wp_insert_post
- create comment box in woo-commerce shop order [closed]
- Product variation attributes does not appear as it should in the cart – woocommerce [closed]
- Hide decimal on hompage, category and product page
- Get order_id from the product_id in woocommece [closed]
- Woocommerce: how to know if the customer is canceled the order or the shop owner? [closed]