• Hi,

    I have just updated Ocean Extra and now my site is broken when Preloader is enabled. I have included the error_log below. Seems to be related to // If Gutenberg?

    [09-May-2025 15:02:05 UTC] PHP Warning:  Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265
    [09-May-2025 15:02:06 UTC] PHP Warning: Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265
    [09-May-2025 15:02:11 UTC] PHP Warning: Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265
    [09-May-2025 15:02:15 UTC] PHP Warning: Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265
    [09-May-2025 15:02:18 UTC] PHP Warning: Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265
    [09-May-2025 15:02:19 UTC] PHP Warning: Undefined variable $get_content in /home/public_html/wp-content/plugins/ocean-extra/includes/preloader/preloader.php on line 265

    Line 265:

    echo do_shortcode( $get_content );

    Any help would be greatly appreciated. I’ve disabled (Customise > Site Preloader > Enable Site Preloader Toggle On/Off for now as a workaround.

Viewing 1 replies (of 1 total)
  • Hello @davidblood,

    Thank you for reaching out,

    The issue you mentioned is actually just a simple warning and doesn’t hurt your site.
    You can disable WordPress debugger so that the message doesn’t appear: https://wordpress.org/support/article/debugging-in-wordpress/#wp_debug.

    However, since I can’t reproduce it on my side, I’d like to know how exactly it can be replicated. Also, please let me know from which version you updated to the latest one.

    What settings have you configured under the Preloader settings?
    It’s possible that you previously had a template set for the Preloader display, and that template has since been deleted, could that be the case?

    In any case, I believe recreating a template and assigning it again should remove the warning, or you could configure different Preloader settings. Here is a related article for your reference: https://docs.oceanwp.org/article/908-customizer-site-preloader.

    Please recheck the issue on your end and let us know the outcome.

    I hope it helps,
    Best Regards

Viewing 1 replies (of 1 total)

The topic ‘Undefined variable’ is closed to new replies.