[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4811
  • Last Modified:

Stop Adsense Security Error: Content at http://googleads.g.doubleclick.net/ may not load data from...

Google has been aware for over a year that their Adsense code causes FireFox to report a security error:

Security Error: Content at http://googleads.g.doubleclick.net/ may not load data from...

However, they have done nothing about it, and refuse to even acknowledge the issue despite massive amounts of complaints from Adsense publishers. My question is there anyway around this? Normally I would not care, but...

On my website, I load all the adsense ads at the bottom of the page. Then I use javascript to reposition them. I do it basically instantly, so you can't even tell. I can't use css because the layout is too complicated. However, moving the ads instantly seems to cause this security error about 50 times a second for 10 seconds! Meaning any page I load I get 500 errors! It I delay the moving of the ads by a second, or add it to the onload event, then I get 2 errors, not 500. However, delaying the ads 1 second is not feasible and would descrease revenue. So, does anyone have a solution?
0
SabreCEO
Asked:
SabreCEO
  • 3
1 Solution
 
SabreCEOAuthor Commented:
Well I'd still like to fix the error. But I have a solution not to cause it 500 times by moving the ad. Now what I do is immediately calculate the position of the holder for the ad, then position the ad absolutely inside the holder. Then, since some parts of the page expand (which would cause the ads to be in the wrong place when positioned absolutely) I then move those inside the holder and set their position to static when onload is fired.

-Mark
0
 
gwkgCommented:
Maybe loading adsense in an iframe will stop the errors
http://www.jguru.com/forums/view.jsp?EID=1305379
 
0
 
SabreCEOAuthor Commented:
Same errors, just they come from the iframe (which FireFox still reports). Doesn't make a difference. The errors are caused by the javascript that Google Adsense uses since it try to access content across domains, which is not allowed. I'm going to assume there's no way to stop the errors completely, since you're not allowed to change Google's code anyway per their terms and conditions, and that's where the issue is.

-Mark
0
 
SabreCEOAuthor Commented:
This doesn't solve the Google Adsense errors, which there doesn't seem to be a solution to. However, as per my first post on how to load the ads at the bottom of the page, and then move them via javascript and css. I realized that actually moving the element in the dom causes it to refresh, which is a violation of Google's tos. However, if you just move the ads relative to the holder by using javascript to absolutely position them (but leave them where they are in the dom) that works fine. And if any part of the page expands, just have the ads repositioned again when you do that.

This seems like a better solution than an iframe, since it's on the same page, and Google can easily crawl it for content and relative ads. It also works with any ads, not just Google.

-Mark
0
 
Jay1607Commented:
Has any one ever found a solution to the original problem posted in this thread?  By this and other discussion, this problem seems prevalent and without resolution.

I'm most interested in knowing if this error is effecting revenue.  Are there impressions or clicks that are not being recorded because of this error?
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now