Tracking link in WooCommerce email – CMS & WordPress – SitePoint Forums

Tracking link in WooCommerce email – CMS & WordPress – SitePoint Forums


I’m trying to get the tracking link added to a WooCommerce email and I think I have incorrect syntax. Would appreciate some help. Here is the section in question:

	<?php
	/* translators: %s Order date */
	printf( esc_html__( 'Tracking number : echo "   <a href=\\"https://www.fedex.com/fedextrack/?trknbr=%2$s\\">%2$s</a>";', 'woocommerce' ), esc_html($shipping_carrier), esc_html( $ups_trackingno ) );
	?>
It's outputting this on the email message:
Tracking number : echo " <a href=\"https://www.fedex.com/fedextrack/?trknbr=277442046164\">277442046164</a>";

I want it to output this on the email (with the number being the link):

Tracking number: 277442046164




Source link