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.
When I used this module on an existing site which uses context for block placement, all the blocks dissapeared.
This is because both modules use theme_blocks. It was fixed with a couple lines of code (see patch).
Comment | File | Size | Author |
---|---|---|---|
#2 | esi_context_compat_2.patch | 972 bytes | askibinski |
esi_context_compat_1.patch | 1.48 KB | askibinski |
Comments
Comment #1
askibinski CreditAttribution: askibinski commentedWith above patch in place and the one included in the next comment, you can just use the tpl.php file provided by context called "context-block-editable-region.tpl.php" and override it with someting like:
In addition you also need to patch esi.inc which handles the request for the block content. Otherwise the core block_list will provide an empty array because block placement is handled by context.
Not sure if this is the best way to do this, but it worked for me...
Comment #2
askibinski CreditAttribution: askibinski commentedpatch mentioned in #2. Should be used together with patch in #1.
Comment #3
mikeytown2 CreditAttribution: mikeytown2 commentedThis has been fixed in the 2.x branch. If I am mistaken please re-open.
Comment #5
dropchew CreditAttribution: dropchew commentedHi,
Reopening for 7.x version. I enabled the esi context module but the block added by context are gone... am I missing something? thanks!
Comment #6
manarth CreditAttribution: manarth commentedHi Dropchew,
If you're still experiencing the same problem, can you open a new ticket? ESI does have support for working with context. Perhaps the block disappeared because it's being rendered as an tag, and varnish isn't processing ESI tags? If so, the new Ajax rendering feature may help, by providing a client-side fallback renderer.