4

All that is output on the page is the domain name of the advertiser, for example 'www.solar-aid.org'. The rest of the content is stripped, I believe because of a document.write() statement.

I'd like to know if this is a common issue or something wrong with our setup. There are three domains causing the issue, which we've blocked from Adsense as a result.

  • solar-aid.org
  • kiva.org
  • grameenfoundation.org

Given the type of organizations I think they may be within the default group of 'public service ads' within the Backup Ads setting. If the issue doesn't completely resolve itself soon (one customer of ours complained today, even though I blocked them 5+ days ago), I'll disable public service ads and select the 'fill space with a solid color' option.

1

In JavaScript, document.write() simply prints out text. I am pretty sure that it wouldn't strip the page of HTML unless it were missing a quote, in which case it would strip everything until the next quote appeared in the page.

If you could post some code of one of those domains, it would be a lot more helpful. Just like in HTML, JavaScript needs everything to be closed in the proper place in order to function correctly. However, usually the browser will see the syntax error, and simply stop executing all JavaScript on the page.

Knowing how your webpage is built too would help, if it has major PHP elements, or it's plain HTML or HTML with CSS/JavaScript.

I'm going to assume that you're using HTML with CSS/JavaScript for your webpage, and that the ad is at the top of the page or the first thing in the HTML body. A possible fix would be to sift through the code and look for syntax errors.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.