Error message after upgrade, undefined width/height

#826477
  • Resolved Michelle McGinnis
    Rank Math business

    Hi, I get this message at the top of the front end of the website on every page after upgrading to the latest version of RankMath:

    Warning: Undefined array key “width” in /code/wp-content/plugins/seo-by-rank-math/includes/modules/schema/class-jsonld.php on line 475 Warning: Undefined array key “height” in /code/wp-content/plugins/seo-by-rank-math/includes/modules/schema/class-jsonld.php on line 476

    I tried deactivating all other plugins and switching to a default theme (2024) and the error persisted.

    System info below.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,

    I’m sorry to hear about the error message you are encountering after upgrading to the latest version of Rank Math. The warning messages you provided indicate an issue related to undefined array keys "width" and "height" in the JSON-LD module of Rank Math.

    To address this issue, you can follow these steps:

    1. Update Rank Math and Other Plugins: Ensure that you are using the latest version of Rank Math and all other plugins on your website.

    2. Check for Theme or Plugin Conflicts: Even though you mentioned that you deactivated other plugins and switched to a default theme, it’s essential to ensure there are no conflicts. You can follow our troubleshooting guide here to identify any conflicts.

    3. Contact Rank Math Support: If the issue persists after following the above steps, please reach out to our dedicated support team by opening a ticket here. Our support team is available 24/7 to assist you further.

    If you need any further assistance or have additional details to share, feel free to reply here, and we’ll be happy to help.

    Looking forward to resolving this issue for you!

    Sources:
    How to Fix Undefined Offset: 0 Warning » Rank Math
    Fatal Error Happening on Some Installations After 1.0.49 Update » Rank Math
    Resolving Rank Math Schema Markup Related Issues
    How to Resolve Wordfence Warning for update-1.0.42.php? » Rank Math

    Hello,

    Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.

    Please head over to your WordPress Dashboard > Rank Math > Titles & Meta > Local SEO and check if you have added an SVG in the logo option. If yes, then that explains the error.

    The issue only occurs when you add an SVG image for the logo of the website under WordPress Dashboard > Rank Math > Titles & Meta > Local SEO because those images don’t have metadata that allows the plugin to read its width and height.

    The only way to resolve the issue is to add an image in JPEG or PNG format that has the metadata for those properties, and our plugin can read it and update the markup correctly.

    Hope that helps and please don’t hesitate to let us know if you have any other questions.

    Hello,

    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 2 replies - 1 through 2 (of 2 total)

The ticket ‘Error message after upgrade, undefined width/height’ is closed to new replies.