fbpx

Description

[wcj_order_checkout_field] shortcode displays WooCommerce order any checkout field by id.

Args

field_id
(required) Order field ID.
Default: None

before
(optional) Text to place before the content. If content is empty this argument is ignored.
Default: None

after
(optional) Text to place after the content. If content is empty this argument is ignored.
Default: None

visibility
(optional) User visibility. Possible values are WordPress user roles (including custom), e.g. administrator, shop_manager, customer, guest etc.
Default: all

location
(optional) Make shortcode results visible only to customers from specific country (by user IP). Value is two letter country code.
Default: all

Examples

Billing Phone

[wcj_order_checkout_field field_id="billing_phone"]

Billing Email

[wcj_order_checkout_field field_id="billing_email"]

Custom Billing Checkout Field

[wcj_order_checkout_field field_id="billing_wcj_checkout_field_1"]

Default WooCommerce Order Fields

billing_first_name The billing address first name.
billing_last_name The billing address last name.
billing_company The billing address company.
billing_address_1 The first line of the billing address.
billing_address_2 The second line of the billing address.
billing_city The city of the billing address.
billing_state The state of the billing address.
billing_postcode The postcode of the billing address.
billing_country The country of the billing address.
billing_phone The billing phone number.
billing_email The billing email.
shipping_first_name The shipping address first name.
shipping_last_name The shipping address last name.
shipping_company The shipping address company.
shipping_address_1 The first line of the shipping address.
shipping_address_2 The second line of the shipping address.
shipping_city The city of the shipping address.
shipping_state The state of the shipping address.
shipping_postcode The postcode of the shipping address.
shipping_country The country of the shipping address.
cart_discount Total amount of discount.
cart_discount_tax Total amount of discount applied to taxes.
customer_user User ID who the order belongs to. 0 for guests.
order_key Random key/password unqique to each order.
order_tax Stores order tax total.
order_shipping_tax Stores shipping tax total.
order_shipping Stores shipping total.
order_total Stores order total.
order_currency Stores currency code used for the order.
payment_method method ID.
payment_method_title Name of the payment method used.
customer_ip_address Customer IP Address.
customer_user_agent Customer User agent.
customer_note Order Notes
Recommended for PDF Invoicing and Packing Slips module
Accessible through:
  • [wcj_order_checkout_field]
Tested on WooCommerce 9.3.2 and WordPress 6.6.2