I have a script on my page which loads content from an ad network into a div. This ad network has an 80% fill rate i.e. it only serves an ad 80% of the time, the other 20% of the time it doesn't show an ad. Sadly, the ad network doesn't provide me with a callback to tell me when it hasn't served an ad. As a consequence, sometimes this div shows an ad, and other times it's blank.
This looks horrendous on my website, and makes me a sad panda. Is there a way to check if any content is visible inside a div? If I knew this, I would know when to show the div, and when to hide it.
This sounds like a hard problem to solve, but I wanted to see if there's any solution. On to you, gurus.