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.
Banners seem to break when "Cache blocks" is enabled on the performance page.
Just to make sure its not an website setup issue... can anyone else reproduce this issue?
Comment | File | Size | Author |
---|---|---|---|
#6 | rotating_banner-no-block-caching-965840.patch | 418 bytes | mstef |
Comments
Comment #1
james.elliott CreditAttribution: james.elliott commentedSeems no one was able to reproduce this. I was not either.
Comment #2
tamsoftware CreditAttribution: tamsoftware commentedI have an issue which could be or not be related. Haven't been able to tie it to anything yet, but sometimes the banners don't show. Slide stays stuck on the first slide, block has twice its normal height and nothing moves. Works on some pages of the site and not on others. Very weird. Not enough info yet but my two cents.
Comment #3
mariano.barcia CreditAttribution: mariano.barcia commentedI'm experiencing this issue. I had to disable "Cache blocks" otherwise the block breaks completely.
I'm using D7.2 and the latest dev version of the module (datestamp = "1301544000" in .info file)
BTW, it gets fixed upon cache clear
Comment #4
mstef CreditAttribution: mstef commentedI can confirm that this is happening, with the latest code (3/31/11). Once the block cache is turned on, and you're NOT logged in, the rotation controls are not available and no rotations happen. After looking at the source, it seems like the JS settings for rotating banner aren't being injected:
I see the drupal_add_js() call inside theme_rotating_banner(), and it's not being hit when the cache is turned on.
Comment #5
mstef CreditAttribution: mstef commentedBest option to just set the block to not be cached in hook_block_info()? Is there a better way to inject the JS and remain cached?
Comment #6
mstef CreditAttribution: mstef commentedSimple 1-line patch following the solution in #5. There could definitely be a better way to do this, but this works (for now).
Comment #7
mstef CreditAttribution: mstef commentedComment #8
tamsoftware CreditAttribution: tamsoftware commented#6 Patch works great here ! Thanks mikestefff !
Franck Horlaville
TAM Software
Comment #9
finngruwier CreditAttribution: finngruwier commentedIn my case auto-rotation did not work for anonymous users. Deactivating block cache helped.