YayMail - WooCommerce Email Customizer
  • Getting Started
    • Introduction
    • How to Install
    • Enter license key
    • System Requirements
    • How To Update YayMail
    • Uninstall and Delete
  • Overview
    • Email Templates
    • Global Header and Footer
    • Settings
    • Addon
    • Preview Email
  • Drag-and-Drop Email Builder
    • The Elements Panel
      • Basic Elements
        • Embed a YayMail shortcode into a button
        • Add HTML and shortcode
        • Duplicate/Copy an Element
      • General Elements
      • WooCommerce Elements
        • Change Order Item Titles
      • Blocks
    • The Patterns Panel
      • Header
      • Footer
      • Banner
      • Pre-Designed Patterns
    • The Settings Panel
      • Global Settings
        • Customize with CSS
        • Hide Elements of Order Table
      • Email Settings
    • History
    • Upper Toolbar
      • Shortcodes
      • Custom shortcode
      • Reset Templates
      • Import/copy template from
  • Visibility Control
  • Guides
    • Display coupons
    • Add column in order item table
  • Developer zone
    • API Demo Plugin
    • Register Templates
      • Register new template
      • Email class
      • Render Templates content
    • Register Elements
      • Register New Elements
      • Element Class
      • Render Element content
      • Default element data
      • Custom Property Editor (coming soon)
    • Register Shortcodes
      • Register New Shortcodes
      • Shortcode Class
    • Custom Hook
  • Integrations
    • Advanced Custom Fields (ACF) by WP Engine
    • Advanced Local Pickup for WooCommerce by Zorem
    • Back In Stock Notifier by codewoogeek
    • Checkout Field Editor by ThemeHigh
    • Checkout Field Editor by WooCommerce
    • Custom Order Status by Nuggethon
    • Custom Order Status by TycheSoftwares
    • Custom Order Status Manager for WooCommerce by Bright Plugins
    • Flexible Checkout Fields by WPDesk
    • FooEvents for WooCommerce
    • Shipment Tracking
    • Software Addon by WooCommerce
    • WooCommerce Admin Custom Order Fields by SkyVerge
    • WooCommerce Order Status Manager by SkyVerge
    • WooCommerce Show Attributes by Isabel Castillo
    • WPML & WooCommerce Multilingual
    • Weglot Translate
    • Loco Translate
    • TranslatePress/Polylang
    • Translate text in YayMail
    • User meta
  • Addons
    • Conditional Logic
    • WooCommerce Subscriptions
    • Germanized for WooCommerce
    • Dokan Multi Vendor
    • AutomateWoo
    • WooCommerce Follow Ups
    • WooCommerce Bookings
    • WooCommerce Gift Cards
    • Smart Coupons
    • WooCommerce Memberships and Teams for WooCommerce Memberships
    • WooCommerce Pre-Orders
    • Parcel Panel Order Tracking
    • WCFM Marketplace
    • Affiliate For WooCommerce
    • Back In Stock Notifications
    • PW WooCommerce Gift Cards
    • Appointments for WooCommerce
    • WooCommerce Bookings And Appointments by PluginHive
    • B2BKing
    • B2B Market
    • B2B & Wholesale Suite
    • TrackShip for WooCommerce
    • SG WooCommerce Order Approval
    • SUMO Subscriptions
    • SUMO Payment Plans
    • WooCommerce German Market
    • WC Vendors Marketplace
    • WooCommerce Print Invoices & Packing Lists
    • WooCommerce Deposits
    • WooCommerce Cart Abandonment Recovery by CartFlows
    • WooCommerce Waitlist
    • WooCommerce Simple Auctions
    • YITH Auctions for WooCommerce
    • YITH WooCommerce Stripe
    • YITH Membership
    • YITH Subscription
    • YITH Booking and Appointment
    • YITH WooCommerce Recover Abandoned Cart
    • YITH Wishlist
    • YITH Pre-Order
    • YITH Gift Cards
    • YITH Review For Discounts
    • YITH Multi Vendor
    • YITH WooCommerce Points and Rewards
    • YITH WooCommerce Request a Quote
    • YITH WooCommerce Affiliates
    • YITH WooCommerce Coupon Email System
    • YITH Advanced Refund System for WooCommerce
    • YITH Easy Login & Register Popup
    • YITH WooCommerce Delivery Date
    • WooCommerce Order Delivery Date Pro
    • Colissimo Shipping Methods for WooCommerce
    • WooCommerce Deposits & Partial Payments
    • Custom User Registration Fields by Addify
    • Quotes for WooCommerce
    • RMA Return Refund and Exchange For WooCommerce
    • License Manager for WooCommerce
    • WooCommerce Product Vendors
    • MultiVendorX
    • WooCommerce Stripe Payment Gateway
    • WooCommerce B2B
    • Order Cancellation Email To Customer
    • WooCommerce Order Delivery
    • Account Funds
    • TeraWallet for WooCommerce
    • Points And Rewards for WooCommerce
    • WooCommerce Split Orders
    • WP Crowdfunding
    • WooCommerce PDF Product Vouchers
    • MultiLocation Inventory & Order Routing
    • Woo Sell Services
    • WooCommerce Return & Warranty Management
    • WholesaleX
    • ShopMagic
    • WooCommerce Contact for Shipping Quote
    • MarketKing
    • AliDropship for WooCommerce
    • Custom Fields by Addify
  • Why Upgrade?
  • OTHER LINKS
    • FAQs
    • Troubleshooting
      • Continuous loading
      • Unable to save template
      • Unable to save Emoji
      • Unable to send test email
      • How to clear cache
      • How to use YayMail with GoDaddy
    • Changelog
      • YayMail Conditional Logic
    • Useful Links
      • AppSumo Deal
    • Support
      • How to pay without PayPal
      • How to renew the license key
      • How to change payment method
  • Articles
    • Design Tips
      • Customize Order Confirmation Email
      • Preview and Test Your Emails
      • Design a Black Friday Banner
      • Embed a Video in WooCommerce Email
      • Add Conditional Logic to WooCommerce Emails
    • Email Marketing
      • Setup Next Order Coupon in WooCommerce Emails
      • Automatically Send “Customer Invoice/Order Details" to Customers
      • Create Emails with Dynamic Content
      • Customize WooCommerce Membership Emails
      • Recover Abandoned Cart
    • Advanced Guides
      • Create WooCommerce Custom Emails Per Product
      • Customize ShopMagic Automation Emails
      • Create Custom Shortcode for YayMail
      • Translate Emails with Loco Translate
Powered by GitBook
On this page

Was this helpful?

  1. Addons

Conditional Logic

Show or hide email blocks based on product attributes, order details, and more

PreviousAddonsNextWooCommerce Subscriptions

Last updated 19 days ago

Was this helpful?

With the , you can choose to display any elements or WooCommerce blocks in the email when one or more conditions are satisfied.

Here are the options provided in YayMail conditional statements.

2 logical operators:

  • All: Returns true if all conditions are true.

  • Any: Returns true if at least one of the conditions is true.

3 comparison types:

  • is

  • is not

  • contains all

And various conditional object properties:

  • Product

  • Product category

  • Product SKU

  • Minimum order total

  • Maximum order total

  • Payment method

  • Shipping method

  • Billing country

  • WooCommerce coupon code

Below you will find an overview table of how it works for a product condition under different cases. The Result column shows the visibility of the email block.

Object
Settings
Order items
Result

Product

is: A

A

show

is: A

A, B

show

is not: A

A

not show

is not: A

B

show

is not: A

A, B

not show

is not: A, B

A

not show

is not: A, B

C

show

is not: A, B

A, B

not show

contains all: A, B

A

not show

contains all: A, B

A, C

not show

contains all: A, B

A, B

show

For instance, you can add a Featured Products section to your email body. And then, create a condition to allow displaying it in emails if the ordered product belongs to a specific category.

By choosing Product category is "Tshirts", you will be able to display these related products when a customer has bought a t-shirt.

With this setup, when a customer buys a t-shirt, they will receive an order confirmation email. This email includes links to other product categories in your shop that you have set. So that you boost the chance of customers visiting your store and further browsing Hoodies/Caps categories.

Other WooCommerce conditional logic options include but are not limited to:

  • Billing country is/is not

  • Product category is/is not/contains all

  • Product is/is not/contains all

  • Product SKU is/is not/contains all

  • Minimum order total

  • Maximum order total

  • Payment method is/is not

  • Shipping method is/is not

  • Coupon codes is/is not/contains all

  • Payment status is/is not

Payment method includes: Direct Bank Transfer, Check Payment, Cash on Delivery, PayPal, Stripe, etc.

Shipping method includes: Flat rate, Free Shipping, Local Pickup, etc.

Payment status includes: Pending Payment, Processing.

Happy customizing! 🪄

YayMail Conditional Logic Addon
How to customize your Woocommerce emails to show/hide email content block
List of conditional logic in YayMail
List of Conditional Logic
Choose Conditional Logic in YayMail