Google Maps - Adsense ads not showing in Internet Explorer
I am trying to display adsense ads on maps, but internet explorer gives me a hard time once again. The ads show on all other browsers I tried (chrome, ff, safari, opeara) but internet explorer. Has anyone encountered this before? here is my code for the admanager:
var publisherID = 'ca-pub-6630823543717184';
var adsManagerOptions = {
maxAdsOnMap : 1,
style: 开发者_运维技巧'adunit',
channel: '5611474977'
};
adsManager = new GAdsManager(map, publisherID, adsManagerOptions);
adsManager.enable();
I am using xhtml1-strict doctype
I have found a solution to this. You have to declare the script version as v=2.x whereas I had v=2
correct way:
<script src="http://maps.google.com/maps?file=api&v=2.x&key=YOUR_KEY_HERE&sensor=false"
type="text/javascript"></script>
I had
<script src="http://maps.google.com/maps?file=api&v=2&key=YOUR_KEY_HERE&sensor=false"
type="text/javascript"></script>
this small ommission was causing IE not to display google ads on my maps. Problem solved!
精彩评论