A client of mine wanted to add some text to the thank you page, the page that customers see after they place an order via the default WooCommerce Checkout page.
In this case scenario, they wanted to add a special coupon discount in order to entice buyers to go back to the website and buy again. Enjoy!
WooCommerce: add text to the thank you page
PHP Snippet: Add Content to the WooCommerce Thank You Page
/**
* @snippet WooCommerce add text to the thank you page
* @how-to Get tutoraspire.com FREE
* @author Tutor Aspire
* @testedwith WooCommerce 4.5
*/
add_action( 'woocommerce_thankyou', 'tutoraspire_add_content_thankyou' );
function tutoraspire_add_content_thankyou() {
echo '