Getting started with the OpenLinkz search widget - read these posts and get up and running

Setting up OpenLinkz OpenLinkz Simplified Changing Appearance of Links OpenLinkz Cheat Sheet

Blogger not compatible with AdSense managed ads?

Lately I have been switching the standard AdSense ads to the new managed ad units on both of my blogs (this one and blog.trade-radar.com). Some of these ads are coded directly in the blog template rather than inside a Blogger Gadget or Widget. A good example of where this kind of coding is required is the sliding ad panel that rises from the bottom of the browser window.

I have also been rolling out a redesign of the TradeRadar blog template. The redesign has required me to make a number of other kinds of changes directly to the template code itself.

Just this week, however, it seems like Blogger has started evaluating Google AdSense code and making undesired changes whenever I save the template.

This is actually the second phase in an aggravating series of events related to inserting AdSense code directly into the blog template.

Problem #1 --

The first problem I encountered had to do with the symbols for Javascript comments. When copying the ad code from the Google AdSense site, the variables that define the ad parameters are surrounded by Javascript comment symbols. Leave the comments in and the ad doesn't work. Take the comments out and the ad works fine.

This seems to be a Blogger situation only. Paste the standard ad code into any web page and it works fine with no changes. Paste the ad code into a Blogger template and it doesn't work.

The solution I have used to date is to delete the comments. Unfortunately, this now leads to the second problem.

Problem #2 --

Blogger doesn't recognize the format for managed ad units. If the ad unit code is surrounded by comment symbols, Blogger will not mess with it. As described above, however, I have found that I needed to remove the comment symbols in order to make the ad code work.

When the ad unit code is not surrounded by comment symbols, Blogger interferes with the code, trying to add a value for the AdSense publisher ID into the google_ad_client variable. This, of course, messes up the ad completely.

The workaround --

I took the Javascript variables that the managed ad needs and saved them into a Javascript file. I uploaded the file to one of my web sites. Then I used a simple script tag to retrieve the file immediately before the Google script tag that activates the ad.

This fixes the problem for now. Of course, it requires that you have your own domain where you can store your Javascript file.

Is anyone else encountering this problem? Do you have a different or better workaround? Feel free to leave a comment and let us know how you are handling this situation.

Posted by TradeRadarOperator at 9/01/2008 09:35:00 PM  

7 comments:

[u][b]Xrumer[/b][/u]

[b]Xrumer SEO Professionals

As Xrumer experts, we secure been using [url=http://www.xrumer-seo.com]Xrumer[/url] quest of a sustained leisure now and know how to harness the titanic power of Xrumer and build it into a Cash machine.

We also yield the cheapest prices on the market. Assorted competitors devise order 2x or even 3x and a lot of the opportunity 5x what we responsibility you. But we feel in providing prominent accommodation at a low affordable rate. The large incidental of purchasing Xrumer blasts is because it is a cheaper substitute to buying Xrumer. So we train to abide by that mental activity in mind and outfit you with the cheapest censure possible.

Not simply do we be suffering with the greatest prices but our turnaround heyday after your Xrumer posting is super fast. We intention pull someone's leg your posting done in the forefront you discern it.

We also outfit you with a sated log of successful posts on manifold forums. So that you can notice seeking yourself the power of Xrumer and how we hold harnessed it to gain your site.[/b]


[b]Search Engine Optimization

Using Xrumer you can trust to see thousands upon thousands of backlinks in behalf of your site. Scads of the forums that your Location you settle upon be posted on have acute PageRank. Having your join on these sites can deep down mitigate found up some top-grade rank back links and genuinely as well your Alexa Rating and Google PageRank rating through the roof.

This is making your put more and more popular. And with this inflate in reputation as grammatically as PageRank you can envisage to lead your place absolutely superiority gamy in those Search Engine Results.
Above

The amount of traffic that can be obtained before harnessing the power of Xrumer is enormous. You are publishing your situation to tens of thousands of forums. With our higher packages you may still be publishing your locality to HUNDREDS of THOUSANDS of forums. Ponder 1 post on a in demand forum will inveterately rig out 1000 or so views, with signify 100 of those people visiting your site. Now devise tens of thousands of posts on fashionable forums all getting 1000 views each. Your freight ordain withdraw sometimes non-standard due to the roof.

These are all targeted visitors that are interested or singular in the matter of your site. Assume how many sales or leads you can achieve with this considerable loads of targeted visitors. You are literally stumbling upon a goldmine friendly to be picked and profited from.

Keep in mind, Above is Money.
[/b]

TRAVERSE B RECOVER YOUR INFERIOR ERUPTION TODAY:


http://www.xrumer-seo.com

Anonymous said...
January 30, 2010 at 5:40 AM  

[B]NZBsRus.com[/B]
Dismiss Laggin Downloads Using NZB Downloads You Can Rapidly Find High Quality Movies, Console Games, Music, Applications and Download Them at Blazing Speeds

[URL=http://www.nzbsrus.com][B]Newsgroup[/B][/URL]

Anonymous said...
February 2, 2010 at 5:25 PM  

Pore as surplus Our Unskilled Prices at www.Pharmashack.com, The Largest [b][url=http://www.pharmashack.com]Online Chemist's workshop [/url][/b] To [url=http://www.pharmashack.com]Buy Viagra[/url] Online ! You Can also Clasp Greater Deals When You [url=http://www.pharmashack.com/en/item/cialis.html]Buy Cialis[/url] and When You You [url=http://www.pharmashack.com/en/item/levitra.html]Buy Levitra[/url] Online. We Also Be subjected to a Tickety-boo Generic [url=http://www.pharmashack.com/en/item/phentermine.html]Phentermine[/url] As a cost to Your Nutriment ! We Ditch of achievement away Cleverness group majuscule respect [url=http://www.pharmashack.com/en/item/viagra.html]Viagra[/url] and Also [url=http://www.pharmashack.com/en/item/generic_viagra.html]Generic Viagra[/url] !

Anonymous said...
February 7, 2010 at 11:13 PM  

Infatuation casinos? experimentation this new [url=http://www.realcazinoz.com]casino[/url] documented and rhyme aside online casino games like slots, blackjack, roulette, baccarat and more at www.realcazinoz.com .
you can also discontinuation our redesigned [url=http://freecasinogames2010.webs.com]casino[/url] orientate at http://freecasinogames2010.webs.com and do in corporeal spondulix !
another lone [url=http://www.ttittancasino.com]casino spiele[/url] impede of events is www.ttittancasino.com , as opposed to of german gamblers, orchestrate magnanimous online casino bonus.

Anonymous said...
February 10, 2010 at 8:10 AM  

Thus, it takes only few acta to fill up online accounting for form with arranging any accident about the borrowed balance. [url=http://paydayloansdepr.co.uk]pay day loans[/url] They don't need assets the loan account well on the due date.

Anonymous said...
December 27, 2012 at 6:33 AM  

[url=http://www.23planet.com]casinos online[/url], also known as settled casinos or Internet casinos, are online versions of top-level ("crony and mortar") casinos. Online casinos approve gamblers to take up and wager on casino games painstakingly the Internet.
Online casinos typically submit on the securities exchange odds and payback percentages that are comparable to land-based casinos. Some online casinos formal higher payback percentages in the plan of function habit games, and some mutate known payout surplus audits on their websites. Assuming that the online casino is using an correctly programmed unreliable consider up generator, catalogue games like blackjack comprise an established espouse aboard edge. The payout shard tail of these games are established off non-standard boost to the rules of the game.
Assorted online casinos sublease or apprehension their software from companies like Microgaming, Realtime Gaming, Playtech, Worldwide Scheme Technology and CryptoLogic Inc.

Anonymous said...
January 13, 2013 at 6:12 PM  

top [url=http://www.c-online-casino.co.uk/]uk bonus casino[/url] check the latest [url=http://www.casinolasvegass.com/]free casino[/url] free no store hand-out at the foremost [url=http://www.baywatchcasino.com/]free largesse casino
[/url].

Anonymous said...
February 4, 2013 at 5:50 PM  

Post a Comment

Digg!



 
Support our sponsors!
Close this ad panelX