Thank You Page

WooCommerce Replace “Thank You. Your Order Has Been Received” Text

Pre-Requisites

There are no pre-requisites in order for you to be able to implement this solution.

How To Implement This Solution?

Simply copy the pre-coded solution to your active theme’s functions.php or preferably the Code Snippets Plugin.

About This Solution

Personalising the intro text on the WooCommerce Thank You page (order received endpoint) can greatly enhance the customer experience. Even just adding the customer’s first name can give that text the personable spin it lacks. If you’re using WooCommerce to take bookings, service appointments, or to sell events “Thank you. Your order has been received” doesn’t really make much sense. This quick guide shows you how to add the customer first name to the intro text and change the text completely without having to edit the template files which as you know, we strong recommend against.

/**
* Snippet Name:     Change thank you page intro text on the WooCommerce Thank You Page.
* Snippet Author:   ecommercehints.com
*/

add_filter( 'woocommerce_thankyou_order_received_text', 'ecommercehints_thank_you_intro_text', 20, 2 );
function ecommercehints_thank_you_intro_text( $thank_you_title, $order ){
return '<br>Relax ' . $order->get_billing_first_name() . ', you\'ve secured your spa booking!';
}

Snippet Benefits

  • Personalise the thank you message on the WooCommerce Thank You page
  • Add more context to the thank you intro text, in-line with your product range.
  • Show customers you’ve gone to the effort of editing the default message to thank them personally.

100 WooCommerce Conversion Rate Optimisation Tips

This field is for validation purposes and should be left unchanged.

Let’s collaborate!

Need to outsource WordPress development?

Join forces with UnlimitedWP for an outsourced white label web development service you can truly rely on.

First Timer Here?

Sign up to receive 20% off on your first month with us.

26027
WELCOME OFFER