I had the need to not display certain ads when browser dropped below a certain width. I could hide the blocks with the css of "display: none;" but then the impression was still being counted. So I updated the simpleads.cycle.js to check to see if the containing block had a display attribute value of 'none', and if so, then not call the impression callback. I'm posting a patch here in case this is useful to anyone - it may be a bit specific in nature for general use, but I'm happy to refactor if anyone has the need.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

minnur’s picture

Status: Needs review » Closed (won't fix)