Learn how to use the default value helper function to handle empty values in shortcodes
default
helper function allows you to specify a fallback value when a shortcode field is empty. This ensures your emails always display something meaningful, even when data is missing.
default
is the function nameshortcode_value
is the primary value you want to displayfallback_default_value
is what will be displayed if the shortcode_value
is emptylead.full_name
exists:
lead.full_name
is empty:
company.contact_phone
exists:
company.contact_phone
is empty: