Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I always customize themes with a subtheme and upon creating a subtheme with tweme I received the following notices:
- Notice: Undefined variable: has_sidebar_second in include() (line 58 of /home/grumble/public_html/insite/sites/all/themes/tweme/templates/page.tpl.php).
- Notice: Undefined variable: content_cols in include() (line 55 of /home/grumble/public_html/insite/sites/all/themes/tweme/templates/page.tpl.php).
- Notice: Undefined variable: has_sidebar_first in include() (line 47 of /home/grumble/public_html/insite/sites/all/themes/tweme/templates/page.tpl.php).
- Notice: Undefined variable: has_header in include() (line 34 of /home/grumble/public_html/insite/sites/all/themes/tweme/templates/page.tpl.php).
- Notice: Undefined index: hidden in include() (line 9 of /home/grumble/public_html/insite/sites/all/themes/tweme/templates/page.tpl.php).
Which seem to be the root of an issue with blocks not showing though correctly specified at admin/structure/block.
I don't have a chance to troubleshoot/patch this right this second, but I just wanted to post it in the meantime.
Will submit patches as soon as I get a chance.
I was about to create a drupal bootstrap based theme myself-- so thanks for doing it!
Comment | File | Size | Author |
---|---|---|---|
#4 | tweme_sub.zip | 16.64 KB | neRok |
Comments
Comment #1
WorldFallz CreditAttribution: WorldFallz commentedI've tried wrapping them with isset(), but I'm still not getting any sidebars to print-- or any regions for that matter. Not sure what else to look at.
Comment #2
iaminawe CreditAttribution: iaminawe commentedI am also not getting any of the main theme regions to print. In addition when I move blocks around in my subtheme, their position is not saved on the admin screen either which I am using the same subtheme on.
Please can you provide an example of a sub theme that works correctly with Tweme, Great theme by the way, definitely the best to the twitter bootstrap modules I have looked into so far. Thank you.
Comment #3
iaminawe CreditAttribution: iaminawe commentedPlease provide some guidance for this - I will turn it into documentation for the theme when I get it working
Is there something specific one needs to do with the subtheme to get the regions working correctly?
Comment #4
neRok CreditAttribution: neRok commentedI made a subtheme as per normal, and whilst I dont have any blocks, I also do not have any errors. Subtheme attached that you can just unzip into sites/all/themes
Comment #6
anydigital CreditAttribution: anydigital commentedMany thanks neRok for the assistance!
Please let me know if you have any further questions related to subtheming.
I'm going to create standalone subtheme based on Tweme and also publish it on Drupal.org.
Comment #7
msimanga CreditAttribution: msimanga commentedI created a sub theme of my own and the side blocks would not show. I also tried out neRok's sub_theme in post #4 and still no side bars. Anyone have a solution?
Comment #8
msimanga CreditAttribution: msimanga commentedI had a look at the template.php file in the tweme folder and found that this is the issue:
I tried to override this function in my sub theme but this did not seem to work. So in the end I modified the tweme's template.php file. Not the most elegant solution
Comment #9
anydigital CreditAttribution: anydigital commentedNo. you shouldn't change _tweme_is_tweme() function.
Just change one line in your subtheme's
page.tpl.php
.From:
To:
Comment #10
anydigital CreditAttribution: anydigital commentedI also get rid of _tweme_is_tweme() :-)
Just use the latest dev version of Tweme. Your subtheme will work even without any changes mentioned above.
Comment #11
anydigital CreditAttribution: anydigital commented