Problem/Motivation
When the Zen base theme is updated on a site, the following PHP warnings appear on each page:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 111 of sites/all/themes/zen/template.php).
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 112 of sites/all/themes/zen/template.php).
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 113 of sites/all/themes/zen/template.php).
This is due to a core bug preventing the default values of Zen's theme settings from being inherited by sub-themes. #761608: Missing theme settings values because list_themes() has inconsistent theme object data :-(
Proposed resolution
We need to get #761608: Missing theme settings values because list_themes() has inconsistent theme object data fixed.
But the workaround for this is to add these lines to your sub-theme's .info file:
settings[zen_html5_respond_meta][] = respond
settings[zen_html5_respond_meta][] = html5
settings[zen_html5_respond_meta][] = meta
Original report by Mon Reveur
When I updated Zen theme (7.x-5.x-dev) on 11/29/11, I ran a "CRON" and received the following:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 111 of /home/everyday/public_html/sites/all/themes/zen/template.php).
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 112 of /home/everyday/public_html/sites/all/themes/zen/template.php).
Warning: in_array() [function.in-array]: Wrong datatype for second argument in zen_preprocess_html() (line 113 of /home/everyday/public_html/sites/all/themes/zen/template.php).
Comments
Comment #1
KrisBulman CreditAttribution: KrisBulman commentedI also got this today, it seems to be something with the html5 meta variables
Comment #2
Mon Reveur CreditAttribution: Mon Reveur commentedhmmm... I wonder if the 11/30 version fixes the problem but it's not showing up on my website as being available.
Comment #3
Mon Reveur CreditAttribution: Mon Reveur commentedOk... Tried using the version listed here on the project page which is dated 11/30... Installed it... and it still says 11/29 on the "available updates" report. I was hoping whoever is working on this project would have fixed it without realizing.
Comment #4
JohnAlbinThe problem is that we added a new theme setting to Zen over in #1154358: Add theme setting for skip link text It's a sweet feature that makes configuring the "skip link" a snap.
HOWEVER… there is a core bug preventing Zen's theme settings defaults from being inherited by sub-themes. #761608: Missing theme settings values because list_themes() has inconsistent theme object data :-(
The workaround for this is to add these lines to your sub-theme's .info file:
I was about to release Zen 7.x-3.2, but I realized that all the sub-theme's that don't override Zen's html.tpl.php will break. Since they won't inherit the new "skip link text" default value from Zen's .info file, their skip link will have NO TEXT AT ALL. Not exactly "accessible". :-(((
Comment #5
JohnAlbinThis bug is fixed in Drupal 8 now. Waiting on it being committed to Drupal 7.
Comment #6
JohnAlbinComment #7
Liam MorlandCorrect tag
Comment #8
JohnAlbinRemoving tag
Comment #9
JohnAlbinMarking #1555356: Errors following 7.x-5.0 update as a duplicate.
Comment #10
JohnAlbinThis has been fixed in D7 core.
Comment #11.0
(not verified) CreditAttribution: commentedAdd issue summary