/* javascript component called 17-OCT-2007 15:30:03 with id parents-home */ // ensures same ad can't display in two slots of the same size function removeFromAdList(alist, html) { var tmp = new Array(); var j = 0; for (var i = 0; i < alist.length; i++) { if (alist[i] != html) { tmp[j] = alist[i] ; j++ } } return tmp; } // gets a random member of the array for that slot function getAds(pos) { if (eval('window.' + pos)) { var adLength = eval(pos + '.length'); var rndNum = Math.floor(Math.random() * adLength); var html = eval(pos + '[rndNum]'); if (adLength > 0) { if (pos == 'top' || pos == 'bottom') { document.write(html); if (window.bottom) { bottom = removeFromAdList(bottom, html); } else if (window.bottom_left) { bottom_left = removeFromAdList(bottom_left, html); bottom_right = removeFromAdList(bottom_right, html); } } else if (pos == 'bottom_left') { document.write(html); bottom_right = removeFromAdList(bottom_right, html); } else { document.write(html); } } } } function getDoubleAds(pos) { ad_ar = eval('window.' + pos); if (ad_ar && ad_ar.length > 0) { document.write('
| ' ); if (window.bottom) { getAds('bottom'); } else { getAds('bottom_left'); } document.write( ' | ' + '' ); if (window.bottom) { getAds('bottom'); } else { getAds('bottom_right'); } document.write( ' |
';
left[1] = '
';
left[2] = '
';
left[3] = '
';