I want to add the product link in the Processing Order email which User receives when order. When an order is placed an Order Email sent, I want to get the product link there when user clicks redirects to the detail product page when clicked. Is there any way, I get the product link or the Product Title would Hyperlink.
THANKS
Adding a simple product. Adding a Simple product is similar to writing a post in WordPress. Go to WooCommerce > Products > Add Product. You then have a familiar interface and should immediately feel at home.
To change the subject and content of the email notifications, navigate to WooCommerce > Settings > Email, pick an email you would like to edit then click Manage. In this case, I've picked the Processing Order email to send to my customer to notify them about their order confirmation.
You can customize the emails via your wp-admin > WooCommerce > Settings > Emails. Here you'll find the ability to customize all of the emails that WooCommerce sends both to you as a store admin, and to your customers.
The answer from gunbunnysoulja works great but needs two little updates:
The updated answer is as follows:
add_filter( 'woocommerce_order_item_name', 'display_product_title_as_link', 10, 2 );
function display_product_title_as_link( $item_name, $item ) {
$_product = wc_get_product( $item['variation_id'] ? $item['variation_id'] : $item['product_id'] );
$link = get_permalink( $_product->get_id() );
return '<a href="'. $link .'" rel="nofollow">'. $item_name .'</a>';
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With