Make WordPress Core

Opened 9 years ago

Closed 9 years ago

#30424 closed defect (bug) (invalid)

Customize errors

Reported by: grayhunter's profile GrayHunter Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.0
Component: Customize Keywords: reporter-feedback
Focuses: administration Cc:

Description

We are having several errors at /wp-admin/customize.php (even with switched OFF debug mode O_o) - here they are:

Warning: Invalid argument supplied for foreach() in /var/....ru/wp-includes/class-wp-customize-widgets.php on line 175

Warning: Invalid argument supplied for foreach() in /var/....ru/wp-includes/class-wp-customize-widgets.php on line 215

Warning: Invalid argument supplied for foreach() in /var/....ru/wp-includes/class-wp-customize-widgets.php on line 215

How can we fix or at least hide these errors?

We have already tried different themes, different sub-sites, disable plugins, add and delete widgets - useless...

P.S.- we are using WP MU 4.0.1, no customising of WP were made.

Attachments (1)

errors.png (49.3 KB) - added by GrayHunter 9 years ago.
how errors look

Download all attachments as: .zip

Change History (7)

@GrayHunter
9 years ago

how errors look

#1 @GrayHunter
9 years ago

  • Keywords needs-patch added

Also this may be interesting:

Widget functionality in customizer does not work. I can add a widget via customizer, save, but when I refresh the page - no any widgets were added (the same with deleting). But if I do the same in /wp-admin/widgets.php - everything is OK.

#2 @GrayHunter
9 years ago

  • Severity changed from normal to major

Bingo! I got the problem:
If you use quotation marks (like ") in the title of the blog or description - you got the errors. For example - print this as the blog title: My "test"

So, how could I fix it? Help me pls.

#3 @jeremyfelt
9 years ago

  • Focuses multisite performance removed
  • Keywords reporter-feedback added; needs-patch removed
  • Severity changed from major to normal

Hi GrayHunter, thanks for the report.

I'm not able to reproduce the issue in WordPress trunk with Twenty Fifteen and no plugins installed. I can save My "test" as a site title and add widgets while using the customizer. Can you provide step by step details on how to achieve the error, ideally with all plugins disabled and while using one of the default themes.

#4 @SergeyBiryukov
9 years ago

The warning means that json_decode() in line 149 failed to get a valid JSON response.

Are there any errors in the server log files other than the ones above?

#5 @GrayHunter
9 years ago

Thank you all for your answers!

"Are there any errors in the server log files other than the ones above?" - what exactly logs I should look for? Where are they at CentOS 6?

#6 @westonruter
9 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

The error relates to the WP_Customize_Widgets::$_customized not being set yet. This code in 4.0.1 was changed a lot in 4.2 to clean up how previewed widget settings are accessed (see #30936), so I believe this issue is no longer valid.

Note: See TracTickets for help on using tickets.