Title: Deprecated code within email-cart.php
Last modified: October 30, 2019

---

# Deprecated code within email-cart.php

 *  Resolved [jebanks](https://wordpress.org/support/users/jebanks/)
 * (@jebanks)
 * [6 years, 7 months ago](https://wordpress.org/support/topic/deprecated-code-within-email-cart-php/)
 * Good Morning,
 * I wanted to let you know that I had the following issue with the Save & Share
   Cart when attempting to share a cart via email:
 * [23-Oct-2019 19:32:45 UTC] The WC_Cart::get_remove_url function is deprecated
   since version 3.3. Replace with wc_get_cart_remove_url.
    [23-Oct-2019 19:32:45
   UTC] The WC_Cart::get_item_data function is deprecated since version 3.3. Replace
   with wc_get_formatted_cart_item_data. [23-Oct-2019 19:32:45 UTC] PHP Fatal error:
   Uncaught ArgumentCountError: Too few arguments to function Kadence_Woomail_Designer::
   add_email_header(), 1 passed in C:\inetpub\wwwroot\Carriers\wp-includes\class-
   wp-hook.php on line 286 and exactly 2 expected in C:\inetpub\wwwroot\Carriers\
   wp-content\plugins\kadence-woocommerce-email-designer\kadence-woocommerce-email-
   designer.php:560
 * Stack trace:
    #0 C:\inetpub\wwwroot\Carriers\wp-includes\class-wp-hook.php(286):
   Kadence_Woomail_Designer->add_email_header(‘ ‘) #1 C:\inetpub\wwwroot\Carriers\
   wp-includes\class-wp-hook.php(310): WP_Hook->apply_filters(”, Array) #2 C:\inetpub\
   wwwroot\Carriers\wp-includes\plugin.php(453): WP_Hook->do_action(Array) #3 C:\
   inetpub\wwwroot\Carriers\wp-content\plugins\woocommerce-email-cart\email-cart.
   php(1118): do_action(‘woocommerce_ema…’, ‘ ‘) #4 C:\inetpub\wwwroot\Carriers\
   wp-content\plugins\woocommerce-email-cart\email-cart.php(303): WC_Email_Cart-
   >format_email(‘<style>\t\t\r\n\t\t/*…’, ‘ ‘) #5 C:\inetpub\wwwroot\Carriers\wp-
   content\plugins\woocommerce-email-c in C:\inetpub\wwwroot\Carriers\wp-content\
   plugins\kadence-woocommerce-email-designer\kadence-woocommerce-email-designer.
   php on line 560
 * To resolve the issue, I had to modify the following code within the email-cart.
   php:
 * The following code:
    do_action( ‘woocommerce_email_header’, $heading ); echo 
   $message; do_action( ‘woocommerce_email_footer’ );
 * had to be updated to:
    do_action( ‘woocommerce_email_header’, $email_heading,
   $email ); echo $message; do_action( ‘woocommerce_email_footer’, $email );
 * Thank you,
    Jake
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fdeprecated-code-within-email-cart-php%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  Plugin Author [Ankit Gade](https://wordpress.org/support/users/wpgurudev/)
 * (@wpgurudev)
 * [6 years, 6 months ago](https://wordpress.org/support/topic/deprecated-code-within-email-cart-php/#post-12196374)
 * Hi,
 * Thanks for contacting support forum.
 * I believe that you are using different plugin and those errors are getting generated
   by that plugin.
 * Could you please check once and let me know?
 * Regards,
    Ankit G.

Viewing 1 replies (of 1 total)

The topic ‘Deprecated code within email-cart.php’ is closed to new replies.

 * ![](https://ps.w.org/woo-save-and-share-cart/assets/icon-256x256.png?rev=3066992)
 * [Save and Share Cart for WooCommerce](https://wordpress.org/plugins/woo-save-and-share-cart/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woo-save-and-share-cart/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woo-save-and-share-cart/)
 * [Active Topics](https://wordpress.org/support/plugin/woo-save-and-share-cart/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woo-save-and-share-cart/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woo-save-and-share-cart/reviews/)

 * 1 reply
 * 1 participant
 * Last reply from: [Ankit Gade](https://wordpress.org/support/users/wpgurudev/)
 * Last activity: [6 years, 6 months ago](https://wordpress.org/support/topic/deprecated-code-within-email-cart-php/#post-12196374)
 * Status: resolved