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.
Hi:
Has anyone had success with Panels 2 and blocktheme. I have a panels one implementation that works wonderfully with BlockTheme however when I upgrade to Panels 2, the blocktheme settings are completely ignored.
I am likely missing a setting somewhere but wanted to check here.
Thanks
Comments
Comment #1
merlinofchaos CreditAttribution: merlinofchaos commentedPanels 2 no longer runs things through theme('block') by default, but you can override theme_panels_pane() and set it up so that it does.
Comment #2
amccann CreditAttribution: amccann commentedThanks for the fast response.
Any tips on how I can figure out how to override theme_panels_pane?
Thanks again.
Comment #3
merlinofchaos CreditAttribution: merlinofchaos commentedIt's actually quite easy. Here's a snippet I have running on another site for this:
Comment #4
amccann CreditAttribution: amccann commentedThanks! Works like a charm.
Comment #5
Anonymous (not verified) CreditAttribution: Anonymous commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #6
Igbonine CreditAttribution: Igbonine commentedI know drupalers will not understand why this is a problem for me but the fact is that i have exactly the above problem but don't know where to put the code snippet.
Will be most grateful if somebody can help me.
Thanks.
Comment #7
anahowa CreditAttribution: anahowa commentedis this code working for panels 6.x-2.0-alpha3 and Block Theme 6.x-1.0-beta1 ??
thank you
Comment #8
greg.harveyIs there any update on this for Panels 3? I'm looking at it now, but if someone already knows the answer it'll save me some time. Naturally, I'll post back if I get there first. =)
Comment #9
greg.harveyStrange - looking at the code, the
plugins/styles/block.inc
file contains a function calledtheme_panels_block_style_render_pane()
which *appears* to theme a block in the normal way on output:But BlockTheme is not working on panel pages, so clearly I'm missing something. Will keep digging. =/
Comment #10
greg.harveyGot it! Once you add your content you need to go to the "Style" option on the context menu for that pane and set it to "System block". Then the
block.inc
plug-in is invoked, the output is treated as a normal block and the BlockTheme module does it's thing.