Closed (fixed)
Project:
Zen
Version:
6.x-2.0
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
25 Sep 2010 at 20:25 UTC
Updated:
15 Mar 2011 at 07:43 UTC
1: I installed Drupal via my hosting companies Plesk 'Applications' menu; Drupal 6.1 was installed.
2: I installed zen. Zen theme worked, CSS classes were added to body tag, layout was correct.
3: I then created a sub-theme as directed. Body tag was missing all CSS classes. I played with the various template files, searched the bug database, etc. No luck.
4: Upgraded my Drupal install to 6.19. Subtheme now works as advertised.
4.a: This may have been something specific to my hosting provider; Drupal 'update' does blow away ALL files, after all.
As the version statement claims 6.x, I figured I'd file this just in case it wasn't something particular to my hosting provider.
Comments
Comment #1
Doud commentedHi,
I'm getting the same issue on a fresh install of Drupal 6.19.
As usual when i'm starting a new site, I have installed Drupal and some basic modules (admin_menu, cck and views).
Then I installed Zen, which was working correctly.
I duplicated the STARTERKIT folder in sites/all/themes and have done the usual configuration when starting a new zen sub theme.
I then got the same issue, that i easily fixed by replacing
By
This is working for now but doesn't fix the problem which seems to come from the template.php file from zen theme.
Any ideas ?
Comment #2
Doud commentedFixing the issue title from "body tag not getting classes when Zen is installed on Drupal 6.1" -> "body tag not getting classes"
Comment #3
jix_ commentedIs the following code in your sub theme's template.php?
(And did you replace 'STARTERKIT' with your own theme name?)
Comment #4
johnalbinThis is definitely not a bug. There is something misconfigured with your sub-theme, Doud.
@ggram Not sure why it wasn't working at first. But I'm glad its working now. My best guess is it was something to do with the theme registry cache which got flushed when you upgraded Drupal.
Comment #5
iNik commentedI think this is a bug. I'm having the same problem on a new site that uses a Zen subtheme (zen_ninesixty), but after downgrading to zen-6.x-1.1, the body classes were assigned properly.
Comment #6
jerseycheeseSubscribing.
I also experience this issue in a subtheme in 6.x-2.0, Drupal 6.19
Plenty of theme registry cache dumps and I do have HOOK_theme() in place, correctly named.
The only way I've been able to bring my custom classes I've added to the $classes_array is to do what Doud did, which will have to do for now:
<?php print implode(' ',$classes_array); ?>Comment #7
mndonx commentedSubscribing
Comment #8
johnalbin@iNik From the zen_ninesixty project page: “The 6-5.x version is developed by Amitaibu and is compatible with Zen-6.x-2.x.”
Older versions of Zen ninesixty are only compatible with Zen 6.x-1.x.
Comment #9
DanielIngraham commentedThis is occurring within a sub theme I just created for testing purposes, following the configuration instructions exactly. It's definitely a bug.
Comment #10
ben_m commentedi get the same thing happening with a sub-sub theme of zen. template.php and theme-settings.php inside the sub-sub themes folder causes the WSOD, removing them strips the body classes - the implode fix above works tho.
Comment #11
gmgartner commentedSubscribing
Comment #12
silverfly commentedSubscribing...
...Having the same issue as @jerseycheese. Drupal 6.19, Zen 6.x-2.0, Zen_NineSixty 6.x-4.3
I have a sub theme of sub theme (zen 960). I get the error: (Warning: implode() [function.implode]: Invalid arguments passed in) when I use Doud's code. It does display the body classes though.
Comment #13
designbysoil commentedAny solutions?
Comment #14
johnalbinPeople are piling on different problems into this issue.
@silverfly As I stated earlier Zen_NineSixty 6.x-5.x is compatible with Zen 6.x-2.x, Zen_NineSixty 6.x-4.x and earlier is compatible with Zen 6.x-1.x. You either need to downgrade Zen or upgrade Zen_NineSixty.
@ ggranum: Oh! Re-reading I see it initially didn't work because you were using Drupal 6.1. That version is pretty old and had some bugs in it that Zen originally had to work-around. However, since those bugs were fixed in later versions of Drupal (along with several security fixes), I removed the work-arounds in Zen.
Everyone, some of you are using Zen 6.x-1.x and some Zen 6.x-2.x. They handle body classes differently, so I can't provide support for both versions in one issue. If you are having issues, please open a new ticket, specifiying the version you are using. Thanks!
Comment #15
BoySherman commented@designbysoil: Doud's solution:
print implode(' ',$classes_array);worked for me. Unsure why though as everything looked in place using the Zen 6.x-2.x