• Customer

    Admin Error Log Notice

    Posted by: jasonpel Mar 15, 2018 at 18:48 (8 months ago)
    Hi,
    I am getting this error in an error.log file located in the wp-admin folder:
    [15-Mar-2018 18:38:44 UTC] The WC_Cart::get_undo_url function is deprecated since version 3.3. Replace with wc_get_cart_undo_url.
    Please post your fix to this ticket so I can update my production site.
    Thank you!

  • Supporter

    Posted by: yame, Mar 16, 2018 at 07:16 (8 months ago)

    Hello,

    In the attachment, it says quite clearly.
    You can define where the WC_Cart::get_undo_url function is (just because it is older) then replace by wc_get_cart_undo_url (this is the newer version)
    Please try then tell me your result

    Regards,
    Yame
  • Customer

    Posted by: jasonpel, Mar 16, 2018 at 16:15 (8 months ago)

    Hi,
    I am not a coder. Most support people would just modify/fix the php file and post it back here to this ticket with the location where to replace it in your theme. But no worries, I managed to track down the line of code in your theme file (woo-functions.php) and replace it. Hopefully, this is all that needs to be done.
  • Customer

    Posted by: jasonpel, Mar 16, 2018 at 16:17 (8 months ago)

    Here's another: [16-Mar-2018 16:13:53 UTC] The WC_Cart::get_remove_url function is deprecated since version 3.3. Replace with wc_get_cart_remove_url.

    Maybe you guys need to completely update this file?
  • Customer

    Posted by: jasonpel, Mar 16, 2018 at 16:26 (8 months ago)

    Looks like this is in header-mini-cart.php

    I tried to update the file but it broke my theme:

    [16-Mar-2018 16:27:03 UTC] PHP Fatal error: Call to undefined method WC_Cart::wc_get_cart_remove_url() in .../wp-content/themes/turan/template-parts/header-mini-cart.php on line 58
  • Customer

    Posted by: jasonpel, Mar 16, 2018 at 17:55 (8 months ago)

    So, I just noticed this also breaks the theme: "get_undo_url" to "wc_get_cart_undo_url"
    After replacing function, if you try to remove a product from the minicart, it just spins and does not refresh.
    Going back to original get_undo_url fixes new problem.
    See attached.
    Please update all of these deprecated functions in your theme and post fixed files to this ticket. I will replace them.
    Thank you.
  • Customer

    Posted by: jasonpel, Mar 16, 2018 at 19:34 (8 months ago)

    Here is a copy of the wp-admin/error_log file for the two deprecated Woo functions. Please fix these, test them, and post the updated files to this ticket.
    Thank you!
  • Customer

    Posted by: jasonpel, Mar 19, 2018 at 15:27 (8 months ago)

    HI,

    Please read all my posts above.

    Here are the errors in my logs:

    In the root folder: The WC_Cart::get_remove_url function is deprecated since version 3.3. Replace with wc_get_cart_remove_url.

    In wp-admin folder: The WC_Cart::get_undo_url function is deprecated since version 3.3. Replace with wc_get_cart_undo_url.

    Please update deprecated functions in your theme and post fixed files to this ticket. I will replace them in my production site.

    Thanks
  • Supporter

    Posted by: yame, Mar 20, 2018 at 10:09 (8 months ago)

    I will notice my coder for this issue. I will inform you when I get his feedback
  • Supporter

    Posted by: yame, Mar 21, 2018 at 01:52 (8 months ago)

    Good morning, mate

    I got feedback from my coder. He checked on demo and mini cart still works well. It is still able to fresh.
    The reason is you might customize your site, so it leads to the error. And we do not support for the customized site

    Hope you understand for this
    RGs,
    Yame
  • Customer

    Posted by: jasonpel, Mar 21, 2018 at 03:36 (8 months ago)

    Hi,
    I said that when I replaced these lines as you suggested, it broke the cart. Once I put the original code back, the cart worked fine.
    These are errors that are being written to 2 different error_logs. I haven't customized any of the PHP files. I have only added custom CSS settings to the theme.
    From the errors, you can plainly see that your PHP files contain outdated WooCommerce functions that need to be replaced just like you said above.
    So, please replace these two deprecated functions in your PHP files, test them, and upload them to this ticket once you have them working.
    I will replace them on my production site.
    Soon, I am going to need to charge you guys for support... :)
    Thank you!
  • Customer

    Posted by: jasonpel, Mar 21, 2018 at 04:10 (8 months ago)

    I have uploaded a video that shows the errors being created when products are added to and removed from the cart. This is obviously an issue with the outdated functions related to the cart. I have attached a link to the video in the secret information.

    [21-Mar-2018 04:04:34 UTC] The WC_Cart::get_remove_url function is deprecated since version 3.3. Replace with wc_get_cart_remove_url.
    [21-Mar-2018 04:04:37 UTC] The WC_Cart::get_undo_url function is deprecated since version 3.3. Replace with wc_get_cart_undo_url.

    Errors being written to the root/error_log and wp-admin/error_log.
  • Supporter

    Posted by: yame, Mar 26, 2018 at 09:14 (8 months ago)

    ok mate.
    My coder will check again this issue.
    I am also waiting for his feedback. I will inform you when I get any information
  • Customer

    Posted by: jasonpel, Mar 27, 2018 at 21:18 (8 months ago)

    Hi, any word on this yet. This is the last issue I need to fix with your theme. Let's get it done! :)
    Thanks!
  • Supporter

    Posted by: yame, Apr 3, 2018 at 07:57 (8 months ago)

    I am still waiting for coder. Just because he checked on demo, and did not meet this issue.
    So I think, it is better if you can provide your wp login + FTP.
    He will check your site, and if he meets the problem as you told above, I will ask him to show the way how to fix this for you. And you can do it by yourself
    It's difficult to check on demo without any error

INSTALLATION SERVICE

We offer service for $29. If you would like to use it, please click here to provide your credential information.

CUSTOMIZED SERVICES

Use our expert service to turn your ideas into reality. Click here to provide your needed information.

WORKING TIME

Our support service works from Monday to Friday.
Mean time (GMT +7):
+ 7:30 - 11:30 AM
+ 1:30 - 5:30 PM
We will try to answer all the questions within 24 hours and solve them as quickly as possible