Product Links in
WooCommerce Order Emails

Category: WooCommerce
Image

To link a product name with its product page in your order emails, open the functions.php file of your child theme and add the following snippet of code:

/**
* Product Links in WooCommerce Order Emails
* More tips: https://themes.email/woocommerce.html
*/
   
    add_filter('woocommerce_order_item_name', 'woocommerce_order_item_link', 10, 3);

    function woocommerce_order_item_link( $item_name, $item, $bool ) {
        $url = get_permalink( $item['product_id'] ) ;
        return ''. $item_name .''; 
    }

Tutorials

Purchase WooCommerce Email Templates $35 USD

Each purchase of WET comes with 20 different styles —
and a lifetime of free fresh designs & bug-fix updates.

One purchase for all your future projects.