Forum Moderators: martinibuster

Message Too Old, No Replies

attention IPB users: remove this code for firefox to display your ads

firefox doesn't display adsense ads in IPB forums

         

sallam

1:38 pm on Apr 13, 2008 (gmt 0)

10+ Year Member



Greetings

For months now I've been noticing a sharp decrease both in my adsense page impressions and revenues. Only today I found out that this is because one of IPB forum's js files is using a security code that conflicts with adsense code.

If you're using IPB script for your forum, you need to find and remove the following code from: jscripts > ips_ipsclass.js

if(is_moz&&!is_safari){HTMLDocument.prototype.__defineGetter__("cookie",function(){return null;});window.addEventListener('load',function(){var _a=document.body;var _x=_a.innerHTML;var _y=new RegExp("HTMLDocument\\.prototype",'ig');if(_x.match(_y)){_x=_x.replace(_y,'HTMLDocument_prototype');_a.innerHTML=_x;}},false);}

Once I removed the above code, adsense ads displayed normally in firefox just like it does in IE.

td22

5:19 pm on Apr 13, 2008 (gmt 0)

10+ Year Member



Which version of IBP?

sallam

8:17 pm on Apr 13, 2008 (gmt 0)

10+ Year Member



I've seen this in 2.3.x
not sure if earlier versions have this problem too.

RonS

8:34 pm on Apr 13, 2008 (gmt 0)

10+ Year Member



Good for you!

Glad you found it. Have you seen an increase in number of clicks to go with your increased impressions?

sallam

11:30 pm on Apr 13, 2008 (gmt 0)

10+ Year Member



too early to tell, since its day 1 of code removal. But it seems that there is around 35% increase in both impressions and clicks already. It will be clearer in a week or so.