I've been getting 404 page not found warnings for urls like this: [some path]/google-analytics.com/ga.js
[Some path] differs for each warning. I think it depends on what page the user is on when the path is requested.
I was also getting 404s for some other Google js files, pagead/render_ads.js, pagead/render_ads.js, and a few others using my website's path rather than the path to google. I was able to redirect those with a rewrite rule though.
RewriteRule ^pagead/expansion_embed\.js$ http://pagead2.googlesyndication.com/pagead/expansion_embed.js [R=301,L]
RewriteRule ^pagead/render_ads\.js$ http://pagead2.googlesyndication.com/pagead/render_ads.js [R=301,L]
RewriteRule ^pagead/test_domain\.js$ http://googleads.g.doubleclick.net/pagead/test_domain.js [R=301,L]
RewriteRule ^pagead/(.+)$ http://googleads.g.doubleclick.net/pagead/$1 [R=301,L]
I'm not sure how to fix the [some path]/google-analytics.com/ga.js problem though. Any ideas?
Comments
Comment #1
jcnventuraAre you using the adsense module?? You're the first that seems to be having this problem...
Comment #2
Benj commentedYes, I'm using the adsense module. It seems to be working fine, as far as I can tell, besides click tracking - the log page is empty. But in the general log entries I was finding numerous warnings as described above until I made the Rewrite rules.
Comment #3
jcnventuraHi,
I've just checked the code and all the Javascript is always called with an absolute path. It should never be trying to access it locally, except if your server setup is modified in a way that it 'caches' external resources.
Whatever it is, I doubt that there's anything in the module that is responsible for this behavior.
João
Comment #4
jcnventuraNo further info in more than two weeks. Closing the issue.