It is possible to position blocks into regions using both context and the core blocks module. In my case, I have a load of blocks placed throughout the site using context - these contexts have been well defined and will not change. However, I want to allow some content editors to be able to place additional blocks on the site at will, but I don't want then doing this using content. Instead, I want them to use the much simpler core blocks module.

The problem I have is that it seems that any blocks placed into regions using the core blocks module appear BEFORE the blocks that are included as part of a context, where as I want them to always appear AFTER.

How can I ensure that blocks added to regions with the core blocks module, come AFTER any blocks that are added through context?

Comments

mstrelan’s picture

subscribe

spack’s picture

Exact same issue. Wish I could position my Context blocks in relation to the core blocks.

ronino’s picture

Just did my first steps with context and I would also like to position context blocks arbitrarily in relation to core blocks. I'm working on Drupal 7.

topdillon’s picture

subscribe

VTM’s picture

I took different approach.
It does require some planning and not too much working .

I have created a context per page type (I do not have too many of them), and only for the regions where I may have weight problems.
The result is that for these regions I did not have placed block(s) using the core BLOCK module.
I know that if additional block may be needed, I would add it to any required context.
Anyway it does not happen often.

Hope this tip help.

jim kirkpatrick’s picture

Category: support » task
Priority: Normal » Major

Unless there's a way to reorder blocks built into the Context UI I can't see, this is a major feature regression from 2.x...

What's the best approach here? Hopefully it's one that doesn't need the context & blocks settings on the dozen Context-enabled sites I manage to be re-developed!

(@VTM #5: thanks for the tip, might well do this but it's a LOT of work for the dozen or so sites I run - some have 20 content types!)

ngmaloney’s picture

I was having the same issue. I needed to put the "Main content' block in between 2 other blocks via context. I filed issue 1096352 which creates a proof of concept patch to resolve this issue. The patch is currently for D7 but would be easy to port to D6. It basically allows context settings to override core settings IF the block is defined within context.

I recently discovered the contrib module Context Respect which does the exact opposite, but whose functionality is delivered via a separate contrib module. Would this be a better approach than a patch to context? Or is there an even better solution (via a reactions plugin)?

azinck’s picture

subscribe

ranjeesh’s picture

A weight can be assigned to the blocks in the contexts using which we can manipulate the positioning of the block on the region.

paulocs’s picture

Issue summary: View changes

As context 7.x and 8.x already respect block weights and context 6.x is no longer supported, I'll close this issue.
Thanks.

paulocs’s picture

Status: Active » Fixed
paulocs’s picture

Status: Fixed » Closed (fixed)