Click to See Complete Forum and Search --> : Google ads problem when more than 2


Jix
02-02-2010, 02:10 PM
Strange problem I can't fix. It all started with me trying to have 3 google text ads side-by-side.

I added the google text ads at the bottom of each news article. They appear as displayed on this link (http://www.gameobserver.com/news/inside/all-platforms/-command-conquer-4-tiberian-twilight-open-multiplayer-beta-1146/). At the end of each news article there should be 3 125x125 text ads, side-by-side. One problem: the third one never appears and screws up the rest of the ads to the right of the page (in the Advertising box). 1 ad alone is ok, I get no problems anywhere. 2 ads appear fine, but the skyscraper ads to the right get screwed up. At 3 ads the third one doesn't appear and the side skyscraper ad screws up. I shudder to think what would happen if I'd put 4 ads... Here is the code I used:



<table border=0><tr>

<td>
<script type=\"text/javascript\"><!--
google_ad_client = \"pub-6156873709869941\";
/* 125x125, created 2/2/10 */
google_ad_slot = \"4571094153\";
google_ad_width = 125;
google_ad_height = 125;
//-->
</script>
<script type=\"text/javascript\"
src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">
</script>
</td>



<td>
<script type=\"text/javascript\"><!--
google_ad_client = \"pub-6156873709869941\";
/* 125x125, created 2/2/10 */
google_ad_slot = \"7617265647\";
google_ad_width = 125;
google_ad_height = 125;
//-->
</script>
<script type=\"text/javascript\"
src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">
</script>
</td>



<td>
<script type=\"text/javascript\"><!--
google_ad_client = \"pub-6156873709869941\";
/* 125x125, created 2/2/10 */
google_ad_slot = \"8022534159\";
google_ad_width = 125;
google_ad_height = 125;
//-->
</script>
<script type=\"text/javascript\"
src=\"http://pagead2.googlesyndication.com/pagead/show_ads.js\">
</script>

</td></tr></table>


I put the code between two </div>. And before you ask about the \" \" I have magic quotes on.

It seems like google's script doesn't like the ads side-by side. The same problem appears even when I remove the <td><tr><table> code that makes the ads appear sideways. I'm stumped... Do I need to add code between </script> and the next <script type=\"text/javascript\"> ???

jonmaster
02-02-2010, 05:17 PM
Code looks fine,

just add the height and width property for td

<td width="125" height="125"

you have to work around, and also set the table align="left"

Jix
02-02-2010, 06:20 PM
K, tried. Didn't work. I tried various variations of width (table, row, cells), and nothing. The problem is, even when I put the ads vertically, without a table, I still get that bug. I put google's code clean, with only <br><br> separating each ad, and still get the same problem, so it's not a constriction issue but some anomaly where two of the same ads can't be put back-to-back. Just two of them one after the other gives me problems (400s the rest of the ads on the page). That's why I'm leaning more on the possibility that I have to tell each ad that "yes, you should, like, really REALLY </script>." I tried alternating the sequences of each, thinking that maybe one of them is broken or something, but nope... As soon as two of them are back-to-back, I get an "HTTP 400 - Bad Request" (Firefox gives me the same error).

jonmaster
02-02-2010, 09:43 PM
you donot you try the same adsense codes alone in some seperate HTML file and verify the output.

I think you are missing some closing tag.