[wcj_order_total]
Display WooCommerce order total
Description
[wcj_order_total]
shortcode displays total for WooCommerce order.
Args
Please check shortcodes common args.
- excl_tax
- (optional) Exclude taxes (
yes
).- Default:
no
- Default:
- hide_if_zero
- (optional) Hide output if result equals zero (
yes
).- Default:
no
- Default:
- hide_currency
- (optional) Hide currency symbol (
yes
).- Default:
no
- Default:
- order_id
- (optional) The integer ID for an order.
- Default: The current order ID, if exists
- 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
- billing_country
- (optional) Make shortcode results visible only in orders with specific billing country. Value is two letter country code. Can be comma separated list.
- Default: None
- not_billing_country
- (optional) Make shortcode results visible only in orders excluding specific billing country. Value is two letter country code. Can be comma separated list.
- Default: None
Examples
Display WooCommerce order total excluding taxes, taxes and total including taxes:
[wcj_order_total excl_tax="yes" before="Total excl. TAX: "] [wcj_order_total_tax before="TAX: "] [wcj_order_total before="Total: "]
Accessible through:
- [wcj_order_total]
Hi!
Is it possible to return the number in words?
Hi,
Yes, check out [wcj_order_total_in_words] shortcode.
Best regards,
Rokas – Support Team
Hello,
is possible to have shortcode [wcj_order_total] multiply_by or divide_by? Just like is [wcj_cart_total multiply_by="xxx"]
Thanks
Is it possible to have just the number returned without HTML tags? I would like to fill this into a paypal.me link and thus only need the “naked” digits. Thanks!
Hi Ulli,
All Booster’s shortcodes have
strip_tags
attribute, so you can remove HTML tags with something like this:[wcj_order_total strip_tags="yes"]
Please let me know if that helped or if you have any questions.
Best regards,
Tom