0

I need to have a full screen image carousel and I'm using a sub theme of omega.

Ideally, I'd like to render the image through a custom module which I have put in the branding region. Because the images needs to be full width I need to render the branding region outside the grid.

What's the best way to go about removing the branding region from the grid and rendering it outside?

Thanks,

1 Answer 1

1

This is actually pretty complicated. The major problem is that both the region and the zone that it is in have the grid classes on them.

You need to implement a template_process_zone() in your theme, and then remove the grid classes from $variables["content_attributes_array"]["class"]. You then need to implement a template_process_region() and remove them from $variables["classes_array"].

Any other regions in that zone will then have grid problems, and the containing zone won't have a grid container definition.

Your other option is to use CSS to override the grid definitions for the zone and region. Depending on your site and the theme, you may be able to get away with using a full zone wrapper around things, and then using positioning on the region to make it appear full width.

4
  • I see you asked the same question yourself a year ago - drupal.stackexchange.com/questions/30772/…. Thanks for the advice. I also came up with a hard code hard. Just removing attributes in region.tpl - if (strpos($attributes,'region-carousel') !== false) { print "id=carousel"; } else { print $attributes; }
    – rix
    Commented Feb 19, 2013 at 15:39
  • Where can i implement a template_process_zone - in template.php? Thanks,
    – rix
    Commented Feb 19, 2013 at 15:39
  • The Omega way is in yourtheme/process/process-zone.inc
    – mpdonadio
    Commented Feb 19, 2013 at 15:53
  • Yeah, I didn't mark this as a dup b/c you were asking about a region and not a zone. Similar, but slightly different even though the solution is pretty much the same.
    – mpdonadio
    Commented Feb 19, 2013 at 15:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.