• Hi, on my site (https://enjoysilver.wine) I used polylang for translations, the problem is that when I open a product page (Woocommerce) the error page opens “There has been a critical error on this website.” (the rest of the site and pages work correctly). The site is updated to the latest version of WordPress and PHP (8.1).
    I received the following error on the admin email:
    An error of type E_ERROR was caused in line 144 of the file /data/sites/web/enjoysilverwine/www/wp-content/plugins/polylang/include/nav-menu.php. Error message: Uncaught TypeError: Cannot access offset of type string on string in /data/sites/web/enjoysilverwine/www/wp-content/plugins/polylang/include/nav-menu.php:144
    How can I solve it?
    Thanks!
    Regards,

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Chouby

    (@chouby)

    Hello,
    It seems that an option related to menus has been corrupted (the data received by Polylang is not of the correct type).
    Could you deactivate all your plugins (You can keep Polylang and WooCommerce as I know they don’t cause this issue), switch your theme to Storefront (the default WooCommerce theme) and then go to Appearance > Menus
    On the first menu, change the option “Auto add pages”. Save menu, then restore the option at its initial stage and Save menu again. (This should restore the option in DB correctly).
    Once done, check if you reproduce the issue.
    If all is ok, then activate your theme, your other plugins one by one and check if all is ok.
    If you are lucky, the option won’t be corrupted again. If not, then you’ll at least no where it comes from.

Viewing 1 replies (of 1 total)
  • The topic ‘Error when I open a product page’ is closed to new replies.