AC_FL_RunContent = 0; var timer = 8; var photos = [ ['Free-Golf-Banner.jpeg','Click Here for Free Golf Weekends Information!','www.gaylordmichigan.net/banner/banner_hit_counter.phtml?ad_id=33&url=www.gaylordgolfmecca.com/customer-appreciation-weeks-21/'], ['12700445271270043786Loon_specials_banner.jpg','Stay and Play at the Loon -- Michigan Home to the Butch Harmon Golf School','www.gaylordmichigan.net/banner/banner_hit_counter.phtml?ad_id=40&url=www.loongolfresort.com/']]; var img, count = 0; function startSlideshow() { // cueNextSlide(); img = document.getElementById('banner-photo'); imgLink = document.getElementById('banner-photo-link'); window.setTimeout('cueNextSlide()', timer * 1000); } function cueNextSlide() { var next = new Image; next.onerror = function() { //alert('Failed to load next image'); }; next.onload = function() { img.src = next.src; img.alt = photos[count][1]; img.title = photos[count][1]; img.width = next.width; img.height = next.height; imgLink.href = 'http://' + photos[count][2]; if (++count == photos.length) { count = 0; } window.setTimeout('cueNextSlide()', timer * 1000); }; next.src = 'http://www.gaylordmichigan.net/banner/image/' + photos[count][0]; } addLoadListener(startSlideshow); function makePopup(url, width, height, overflow) { if (width > 640) { width = 640; } if (height > 480) { height = 480; } if (overflow == '' || !/^(scroll|resize|both)$/.test(overflow)) { overflow = 'both'; } var win = window.open(url, '', 'width=' + width + ',height=' + height + ',scrollbars=' + (/^(scroll|both)$/.test(overflow) ? 'yes' : 'no') + ',resizable=' + (/^(resize|both)$/.test(overflow) ? 'yes' : 'no') + ',status=yes,toolbar=no,menubar=no,location=no' ); return win; } function addLoadListener(fn) { if (typeof window.addEventListener != 'undefined') { window.addEventListener('load', fn, false); } else if (typeof document.addEventListener != 'undefined') { document.addEventListener('load', fn, false); } else if (typeof window.attachEvent != 'undefined') { window.attachEvent('onload', fn); } else { var oldfn = window.onload; if (typeof window.onload != 'function') { window.onload = fn; } else { window.onload = function() { oldfn(); fn(); }; } } }