Rotating headers ads?

Neil E.

Active member
Have a look at this test site
I've installed the bd rotating ads 1.62 addon and I'm not getting very good results.
I have 17 ads set to show one at a time, but sometimes they repeat instead of being random.
Also they will go blank once in a while. The worst part is that the header occasionally flashes default XF blue on a page load.
The HTML and CSS are in post #85

Are there any better ways to create a simple rotating ad?

Other suggestions?

Neil E.

Active member
Thanks for pointing me to right tool for the job. I got it set up and working with only a bit of head scratching.

<xen:hook name="ad_header" />
<div class="rotatingAd">
<xen:set var="$banners.1"><a href="" target=_blank</a><img src="" /></xen:set>
<xen:set var="$banners.16"><img src="" /></xen:set>
{xen:raw '$banners.{xen:calc '({$serverTime} % 16) + 1'}'}
No link in the last one yet (sponsor site is not finished).
The target=_blank worked great for opening the link in a new window.
I uninstalled that addon.

One funky thing still occurs; that's the header background flashing default XF blue on a page load (random event).
I doubt this has anything to do with your code as it also happened with the addon. My guess is that EXTRA is not
quite right and somehow the default color does not get intercepted as quickly as it should. Must be a specificity conflict
although it only flashes blue for about 100ms.