HI,

When I go into Appearance > Configure > Slate, I run across these error messages

warning: in_array() [function.in-array]: Wrong datatype for second argument in C:\Users\picardo-alt\Sites\pressflow\modules\system\system.admin.inc on line 405.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in C:\Users\picardo-alt\Sites\pressflow\modules\system\system.admin.inc on line 444.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in C:\Users\picardo-alt\Sites\pressflow\modules\system\system.admin.inc on line 472.

And there are no configuration options available in the content area. Even when I click "reset defaults" the error messages do not go away.

Comments

redraven’s picture

I've got a similar error occurring

warning: in_array() [function.in-array]: Wrong datatype for second argument in .../public_html/modules/system/system.admin.inc on line 405.

davidwhthomas’s picture

same error here:

warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/.../modules/system/system.admin.inc on line 472.
joshmiller’s picture

same error here... saw it when I first enabled the module...

drupalfox’s picture

Same warning after enabling the module.

kiphaas7’s picture

Same here after enabling it... Maybe there is something wrong in the .install?

Aerodynamo’s picture

Subscribing to this... same issues is happening for me.

Also, my "Configuration" menu just decided to disappear, leaving no trace of a menu in Admin. Not sure if this is related.

The lines in questions are...

Line 405:
if ((!$key) || in_array($name, $features)) {

Line 444:
if ((!$key) || in_array('logo', $features)) {

Line 472:
if ((!$key) || in_array('favicon', $features)) {

It is at the stat of each segment. Any idea what it would be doing this?

Hope my info helps.

winnie80’s picture

i think it is due to the fact that within slate.info there's no features values what so ever.
i have tried to add this value to slate like for exampel features[] = logo
but still it's not working
any idea guys

my idea is to use this theme also in this path: admin/content/node
to add all nodes also for selecting node types

jrefano’s picture

i can confirm this bug, same as everyone else.

# warning: in_array() [function.in-array]: Wrong datatype for second argument in /mysiteroot/modules/system/system.admin.inc on line 405.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in /mysiteroot/modules/system/system.admin.inc on line 444.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in /mysiteroot/modules/system/system.admin.inc on line 472.
jrefano’s picture

Version: 6.x-1.0-beta2 » 6.x-1.0-beta3

noticed version was set to beta2, bug exists in beta3

mason@thecodingdesigner.com’s picture

Version: 6.x-1.0-beta3 » 6.x-1.0-beta2

I have the bug as well

 # warning: in_array() [function.in-array]: Wrong datatype for second argument in /Users/mason/www/rml/modules/system/system.admin.inc on line 405.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in /Users/mason/www/rml/modules/system/system.admin.inc on line 444.
# warning: in_array() [function.in-array]: Wrong datatype for second argument in /Users/mason/www/rml/modules/system/system.admin.inc on line 472.
codycraven’s picture

Title: Wrong datatype for second argument » Wrong datatype for second argument - Issue Found

I have tracked down the issue everyone experiences when accessing admin/themes/settings/slate with warnings being thrown about a wrong datatype.

My notes are below:

# warning: in_array() [function.in-array]: Wrong datatype for second argument in *DRUPAL PATH*/modules/system/system.admin.inc on line 405.

File: modules/system/system.admin.inc Within: system_theme_settings()
Line 335 $themes array does not contain object with key 'slate', $themes returned value of call to system_theme_data().

File: modules/system/system.module Within: system_theme_data()
Line 809 $themes array returned value from _system_theme_data() Line: 809

Within: _system_theme_data()
Line 838 $themes array returned value from drupal_system_listing('\.info$', 'themes')

Issue discovered: _system_theme_data('\.info$', 'themes') searches within themes directory of both themes/ and sites/*SITE*/themes for the file needed. However Slate is stored within modules, not themes.

Potential fixes for this would be moving Slate to the themes directory or implementing Slate in a different manner so that it does not appear within the admin/themes/settings page. I do not know if either of these potential fixes are feasible with how Admin module is currently programmed.

codycraven’s picture

Version: 6.x-1.0-beta2 » 6.x-1.0-beta3

Updated Issue version to reflect most current version of Admin module as it is affecting the latest release.

translector’s picture

Subscribing

kevinquillen’s picture

subscribe

nquocbao’s picture

The same thing happened here. When I flush the cache, the configuration page for stale theme disappear

traviscarden’s picture

Title: Wrong datatype for second argument - Issue Found » Wrong datatype for second argument - Found issue, need fix
mmaul’s picture

same error here (drupal 6.15, pathfilter 6.x-2.0-beta3). subscribing … and hoping. ;)

kristijan’s picture

Same here