Forum Moderators: DixonJones

Message Too Old, No Replies

Rotating Banners Help Needed

         

maxbasher

2:36 pm on Sep 16, 2008 (gmt 0)

10+ Year Member



I am tryng to add GA code to my websites rotating (.gif) banners and it is making them disappear

here is the end part of thecode which is not working

if (ad3==15) {
link3="http://www.example.com";
adBanner3="images/global/banners_cml/eolrc.jpg";
width3="160";
height3="600";
alt3="END OF LINE";
}
document.write('<center><a href="' + link3 + '" target="_blank" onClick="javascript:urchinTracker('/banners/right_sky/example.com');">');
document.write('<img src="' + adBanner3 + '" width=' + width3 + ' height=' + height3 + ' border=0 alt="' + alt3 + '"></a>');
document.write('</center>');

and here is the original

if (ad3==15) {
link3="http://www.example.com";
adBanner3="images/global/banners_cml/eolrc.jpg";
width3="160";
height3="600";
alt3="END OF LINE";
}
document.write('<center><a href="' + link3 + '" target="_blank">');
document.write('<img src="' + adBanner3 + '" width=' + width3 + ' height=' + height3 + ' border=0 alt="' + alt3 + '"></a>');
document.write('</center>');

any reasons why this isn't working? cheers in advance

[edited by: engine at 2:45 pm (utc) on Sep. 16, 2008]
[edit reason] Please use example.com [/edit]

epistable

3:26 pm on Sep 16, 2008 (gmt 0)

10+ Year Member



Have you tried it without the "javascript" in there? I.e., instead of:
onClick="javascript:urchinTracker('/banners/right_sky/example.com');">');
using
onClick="urchinTracker('/banners/right_sky/example.com');">');
?
Also, which browser are you testing on?

maxbasher

2:34 pm on Sep 17, 2008 (gmt 0)

10+ Year Member



I am currently testing it on FF 3.0

maxbasher

2:56 pm on Sep 17, 2008 (gmt 0)

10+ Year Member



thanks for the suggestion but it has not worked.

just looked at it in ie 6 and safari and still not working

epistable

7:00 pm on Sep 17, 2008 (gmt 0)

10+ Year Member



Sorry, looks like it was a problem with the escaping. Try this:

document.write('<center><a href="' + link3 + '" target="_blank" onclick="urchinTracker(\'/banners/right_sky/example.com/\')">');

I used firebug in Firefox to track this down.