Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>According to <a href="http://groups.google.com/group/adsense-help-troubleshooting/browse_thread/thread/632a7d4cf3d2e06/da4e75482cc5c027" rel="nofollow noreferrer">this thread on AdSense</a>:</p> <blockquote> <p>Short version, you can't use Adsense via Ajax without breaking the programme policies/t&amp;c's</p> <p>Long version...</p> <p>Ad code passed through an xmlhttp call is not rendered, it's just treated as text (hence, responseText). The only way to execute js code is to use "responseXML" coupled with the "exec()" command.</p> <p>For instance...</p> <p>If your xml contains something along the lines of:</p> <p> This is the content from the external file javascript code goes here </p> <p>You would assign a variable (called page_data for instance) using ajax_obj.responseXML, run the XML through a parser and run</p> <p>exec(js variable or line from XML here);</p> <p>Not really helpful from an Adsense standpoint, but that's how it's done.</p> </blockquote> <p>It's also worth mentioning <a href="http://www.onthoo.com/blog/programming/2008/02/why-i-dumped-gwt.html" rel="nofollow noreferrer">Why I dumped GWT</a>:</p> <blockquote> <p>Another problem were my adsense banners. Since I didn’t have a lot of content on the page, the banners were sometimes off topic. An even bigger problem was that the banners stayed the same when people searched for different keywords (since the ajax refresh didn’t trigger an adsense refresh). I solved this by doing the search with a page refresh instead of an ajax call. The ajax part of the site was limited to sorting, faceting, i18n and displaying tips.</p> </blockquote>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload