var send_autoupdate=null;function AJAX_AutoUpdateBanner_init(a){a=fetch_object(a);if(typeof a=="object"&&a!==undefined&&a!==null){auto_update_banner()}}function update_banner(){if(YAHOO.util.Connect.isCallInProgress(send_autoupdate)){YAHOO.util.Connect.abort(send_autoupdate)}this.banner_container=fetch_object("banner_container");this.updtimer;var a=new Date();this.time=a.getTime()+Math.ceil(Math.random()*autoupdtime);this.sUrl="ajax.php";this.postData="do=updbanner&securitytoken="+SECURITYTOKEN+"&t="+time;this.handleSuccess=function(c){if(c.responseXML!==undefined){var b=c.responseXML.documentElement.getElementsByTagName("bannercontent");banner_container.innerHTML=b[0].childNodes[0].nodeValue}};this.handleFailure=function(b){if(b.responseText!==undefined){alert(b.responseText)}};this.callback={success:handleSuccess,failure:handleFailure,timeout:vB_Default_Timeout,cache:false};this.send_autoupdate=YAHOO.util.Connect.asyncRequest("POST",sUrl,callback,postData);this.interval=function(){this.updtimer=setTimeout("auto_update_banner()",autoupdtime)}}function auto_update_banner(){update_banner();interval()};

