Make WordPress Core

Opened 15 years ago

Closed 15 years ago

#10610 closed defect (bug) (fixed)

Accessibilty Mode, Wrong Datatype

Reported by: dcole07's profile dcole07 Owned by: azaozz's profile azaozz
Milestone: 2.9 Priority: normal
Severity: normal Version: 2.9
Component: Widgets Keywords:
Focuses: Cc:

Description

When I'm on the Widgets page, using the Accessibility Mode, and I click add or edit on a widget, I get the following error on the next page that is loaded.
Error: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument in /wp-admin/widgets.php on line 271, referer: http://example.com/wp-admin/widgets.php[[BR]]

http://core.trac.wordpress.org/browser/trunk/wp-admin/widgets.php#L271[[BR]]

This was in a clean install of WordPress 2.9 revision 11812. No plugins were running, using the default theme, no patches applied.

Change History (3)

#1 @azaozz
15 years ago

Can't reproduce this. It's easy to fix but just curious, can you do var_dump($sidebars_widgets); between lines 37 and 38 in wp-admin/widgets.php.

#2 @dcole07
15 years ago

Just to make sure, I created a new local install of WordPress 2.9 revision 11816, but still got the same thing. Seams odd that it didn't happen for you. Here is the data that is outputted:

array(1) {

wp_inactive_widgets?=>
array(12) {

[0]=>
string(7) "pages-2"
[1]=>
string(10) "calendar-2"
[2]=>
string(10) "archives-2"
[3]=>
string(7) "links-2"
[4]=>
string(6) "meta-2"
[5]=>
string(8) "search-2"
[6]=>
string(6) "text-2"
[7]=>
string(12) "categories-2"
[8]=>
string(14) "recent-posts-2"
[9]=>
string(17) "recent-comments-2"
[10]=>
string(5) "rss-2"
[11]=>
string(11) "tag_cloud-2"

}

}

#3 @azaozz
15 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [11824]) Fix warning in wp-admin/widgets.php when using Accessibility Mode on brand new install, fixes #10610

Note: See TracTickets for help on using tickets.