• Resolved katmacau

    (@katmacau)


    Hello. I have found an issue with WooCommcerce and Hummingbird working together with the default customer location set to “Geolocate (with page caching support).

    This setting in WooCommcece puts a unique url param at the end of each page for gelocation purposes (eg ?v=3a1ed7090bfa). However I noticed that when you add to cart in woocommerce and use the view cart link you get when you add a product to cart that it doesnt include that url. If you view cart page without this URL in there you get the following error:

    Warning: preg_match(): Compilation failed: quantifier does not follow a repeatable item at offset 66 in /home/mydomain/public_html/wp-content/plugins/hummingbird-performance/core/modules/class-page-cache.php on line 631.

    Eg you go to mydomain/cart/ you see the error in the page.
    You go to mydomain/cart/?v=3a1ed7090bfa no error.

    Also do you have a guide for best woocommerce settings with caching and other options?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter katmacau

    (@katmacau)

    Actually I noticed that it was not the cart that was the error but the caching mode in general. That error is appearing on multiple pages unless I deactivate cache. I tried clearing the cache but no luck. Have had to turn off page caching due to the error. Please help.

    Hello @katmacau

    I trust you are doing well!

    I’m sorry to hear that you have this warning. I could not replicate this issue on my end. Would you please switch to a different PHP version and see if the issue is still there?

    Would you please also exclude Woocomerce pages, like Cart, and Checkout from being cached? Please go to Hummingbird > Caching > Page Caching, and add URI from these pages, to the Exclusions filed.

    Please see this screenshot:
    https://monosnap.com/file/jtXVb441dB2GOdzhrZ687gF8AOogrb

    Let us know how it went!

    Kind regards,
    Nastia

    Thread Starter katmacau

    (@katmacau)

    Thank you. I have already excluded the pages but the error was happening on all pages. I can’t change the PHP version as the site is live and may break other things.

    Perhaps this helps but I did deactivate the plugin (to test if it was causing another issue which is wasnt). Before deactivating it worked without issue. After re-activating it then had these issues. Does that help with why it might happen?

    Plugin Support Saurabh – WPMU DEV Support

    (@wpmudev-support7)

    Hello @katmacau,

    I am sorry to know that it did not work in the first case. To try and replicate the same on our end, kindly help us with the following.

    1. Your site WordPress Version
    2. Woocommerce Version
    3. PHP Version

    Please note that if any of the plugins are not updated or the WordPress Version or the PHP version are not updated, it would be difficult to support that case as we offer support only to the updated plugins as there are many circumstances dependent on the plugins as multiple plugin authors update plugins and then our devs also have to make some updates on quite a few things to stabilise things and also bring in new features. So resolving issues which aren’t on the current version is a bit difficult.

    But please send me the details here and we would try and replicate the same on our end and see if there is something we can do here to help you with it and resolve this. I am looking forward to hearing from you.

    Regards,
    Prathamesh Palve

    Thread Starter katmacau

    (@katmacau)

    Hello. The error seems to have resolved itself. I did have the woocommerce pages in the Exclusions list as *\/cart\/ and removed the * prefix but that is the only thing I changed.

    The other thing that changed since last noticing the error was changing the woocommerce default customer location from the geo locate (with page caching support) to the store location as default. Perhaps its a clash with the Geolocate option in woocommerce?

    I am using WP5.3.3. Woocom 3.9.1. On PHP 7.3.17.

    Hello @katmacau

    I hope you’re doing well!

    Glad to know that the issue is resolved. It could be related to the Geolocation option in woocomerce and that it was cached.

    Please make sure you’re having the latest version of the Woocomerce and the Hummingbird plugin. As the warning that was showing up on your site is related to PHP 7.3 version. The oldest version of the plugins is not fully compatible with this version.

    Please update all your plugins, including Woocomerce to 4.1.0 and WordPress core to 5.4.1. to avoid any issues.

    I’ve marked this ticket as resolved. If you do have any followup questions or require further assistance feel free to reopen it and let us know here.

    Kind regards,
    Nastia

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘PHP Error on Woocommerce cart page when Geolocate enabled’ is closed to new replies.