I'm using Drupal 7 with a Zurb subtheme using a two column layout. I'm trying to use the Context module to place a block in the right hand column which is a div with a class of 'group-right'.  I have my 'body' content in group-left and have images in group-right. I did this via the Display Suites manage display functionality. I then created a block menu and I would like to place that in the group-right section over top of the images. I thought I would use the Context module to do this but I only have access to Drupal regions when in there, I have Content, Left Sidebar, and Right Sidebar and none of these give me what I want.

I understand now why I'm seeing no options for group-left and group-right as they are not regions but are simply divs within the region Content. Do I need to create a new region, say 'menu-section' and place that in the div with a class of group-right? Or is there a better way of doing this?

Comments

vm’s picture

I'd generate the new regions as you want to work with blocks. I'd name these regions group-left group-right and inspect the output before proceeding with dealing with divs.

spinsheet’s picture

Thanks for the response. I'm not completely clear on what you're advising so let me further explain my situation. I have a Zurb subtheme that I'm using that currently has the following regions:



regions[header]              = Header
regions[help]                = Help
regions[highlighted]         = Highlighted
regions[featured]            = Featured
regions[content]             = Content
regions[sidebar_first]       = Left Sidebar
regions[sidebar_second]      = Right Sidebar
regions[triptych_first]      = Callout one
regions[triptych_middle]     = Callout two
regions[triptych_last]       = Callout three
regions[footer_firstcolumn]  = Footer one
regions[footer_secondcolumn] = Footer two
regions[footer_thirdcolumn]  = Footer three
regions[footer_fourthcolumn] = Footer four
regions[footer]              = Footer

I'm using Display Suites to lay out the content area using a two column layout. In the region 'Content' DS is adding two DS regions which are divs, one with class 'group-left' and the other with class 'group-right'.  I have the body field in the div with class group-left and my image field in the div with class 'group-right'. What I would also like to have is a content aware menu in the div with class 'group-right'. I was wanting to use the Context module to place the appropriate menu in that div based on the URL. I've done this before using the existing regions and it works well, however, this time I want to place it within a specific div within that region.

If I create a new region I can certainly place the menu in there as desired but then it is no longer sitting directly above the image, it would be in a separate right column effectively giving the page a three column layout, two in the content region ('group-left' and 'group-right') and the one new right rail region.

I tried to create a new region by adding 'regions[right_top] = Right Top' to my theme's .info file and then adding '<?php print render($page['header']); ?>' within the div of class 'group-right' which is in the template file ds-2col.tpl.php. This did not work, I figured it was a long shot but tried it anyway.

I could do this by creating a block field from within the Display Suites Manage Display but I could only choose the one menu that way and that one menu would be the only one that showed, using Context I can added the desired menu based on the URL.

Thanks again for your help with this.