/* [INCLUDE FILE] global */ // Sharing module behaviour function toggleSharingModulePopup() { var sharingBox = document.getElementById( "sharingModulePopup" ); if ( sharingBox.style.display == "none" ) { sharingBox.style.display = "block"; } else { sharingBox.style.display = "none"; } } // homepage animation stuff var anim_current = 1; var anim_info = new Array( 3 ); var anim_data = new Array( 3 ); var anim_link = new Array( 3 ); var anim_file = new Array( 3 ); var anim_path = new Array( 3 ); function $(idToGet) { return document.getElementById(idToGet); } // initialize animation data function anim_init() { // only do this if the animation is available if ($( 'animList' ) == null ) { return false; } var animations = $( 'animList' ).getElementsByTagName( 'li' ); for(var y = 0; y < animations.length; y++ ) { anim_info[ y + 1 ] = animations[ y ]; } if ($( 'animData' ) == null ) { return false; } animations = $( 'animData' ).getElementsByTagName( 'li' ); for (var y = 0; y < animations.length; y++ ) { anim_data[ y + 1 ] = animations[ y ]; } animations = $( 'animData' ).getElementsByTagName( 'a' ); for (var y = 0; y < animations.length; y++ ) { anim_path[ y + 1 ] = animations[ y ].href; } if ($( 'animNumber' ) == null ) { return false; } animations = $( 'animNumber' ).getElementsByTagName( 'a' ); for (var y = 0; y < animations.length; y++ ) { anim_link[ y + 1 ] = animations[ y ]; filename = animations[ y ].href.split( "#" ); anim_file[ y + 1 ] = filename[ 1 ]; animations[ y ].href = "#"; } } function anim_start() { anim_set( 1 ); } // switch to next animation function anim_next() { // make sure the animation can jump forward if ( $( 'animList' ) == null ) { return; } anim_current ++; if ( anim_current > 3 ) { anim_current = 1; } anim_set(); } // switch to previous animation function anim_prev() { anim_current --; if ( anim_current < 1 ) { anim_current = 3; } anim_set(); } function anim_set (anim_new) { // if anim_new is set then change current anim if (anim_new != null) { anim_current = anim_new; } // check animation has loaded ok if (anim_info[anim_current] == null) { return; } // loop through icon holders and set selected value for (var y = 1; y <= 3; y++) { // if selected set class name else remove if (y == anim_current) { anim_info[y].className = 'selected'; anim_data[y].className = 'selected'; anim_link[y].className = 'selected'; } else { anim_info[y].className = ''; anim_data[y].className = ''; anim_link[y].className = ''; } } if ($('animHolder') != null) { $('animHolder').innerHTML = AC_FL_GetContent( 'id', 'animation', 'name', 'animation', 'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0', 'width', '290', 'height', '200', 'quality', 'high', 'bgcolor', '#ffffff', 'menu', 'false', 'allowscriptaccess', 'sameDomain', 'pluginspage', 'http://www.macromedia.com/go/getflashplayer', 'movie', '/swfcontent/' + anim_file[anim_current] + '?url=' + anim_path[anim_current] + '&game_id=' + anim_file[anim_current] + '&page_id=homepage', 'wmode', 'transparent' ); statTracker('/animations/views/homepage/' + anim_file[anim_current]); // loop through icon holders and set selected value for( var y = 1; y <= 3; y++ ) { // if selected set class name else remove if ( y == anim_current ) { //parent.anim_info[ y ].className = "selected"; anim_info[ y ].className = "selected"; anim_data[ y ].className = "selected"; anim_link[ y ].className = "selected"; } else { anim_info[ y ].className = ""; anim_data[ y ].className = ""; anim_link[ y ].className = ""; } } } else { // loop through icon holders and set selected value for (var y = 1; y <= 3; y++) { // if selected set class name else remove if (y == anim_current) { anim_info[ y ].className = 'selected'; anim_data[ y ].className = 'selected'; anim_link[ y ].className = 'selected'; } else { anim_info[ y ].className = ''; anim_data[ y ].className = ''; anim_link[ y ].className = ''; } } frames['animHolderFrame'].location.href = 'animdata.php?anim=' + anim_current; } return false; } // player homepage animation var player_current = 1; var playersAnim_time = 0; var player_info = new Array(3); var player_link = new Array(3); var player_file = new Array(3); // initialize animation data function player_init() { // only do this if the animation is available // player tab info if ($('playerList') == null) { return false; } var animations = $('playerList' ).getElementsByTagName( 'li' ); for (var y = 0; y < animations.length; y++) { player_info[ y + 1 ] = animations[ y ]; } // player id if ( $( 'playerNumber' ) == null ) { return false; } animations = $( 'playerNumber' ).getElementsByTagName( 'a' ); for( var y = 0; y < animations.length; y++ ) { player_link[ y + 1 ] = animations[ y ]; filename = animations[ y ].href.split( "#" ); player_file[ y + 1 ] = filename[ 1 ]; animations[ y ].href = "#"; $( "playerHolder" ).innerHTML = $( "playerHolder" ).innerHTML + AC_FL_GetContent( 'id', 'animation', 'name', 'animation', 'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0', 'width', '290', 'height', '260', 'quality', 'high', 'bgcolor', '#ffffff', 'menu', 'false', 'allowscriptaccess', 'sameDomain', 'pluginspage', 'http://www.macromedia.com/go/getflashplayer', 'movie', '/players/swf/components/featuredplayer?uid=' + player_file[ y + 1 ], 'wmode', 'transparent' ); } } function player_start() { player_set( 1 ); } // switch to next animation function player_next() { player_current ++; if ( player_current > 3 ) { player_current = 1; } player_set(); } // switch to previous animation function player_prev() { player_current --; if ( player_current < 1 ) { player_current = 3; } player_set(); } function player_set( player_new ) { // if anim_new is set then change current anim if ( player_new != null ) { player_current = player_new; } // check animation has loaded ok if( player_info[ player_current ] == null ) { return; } // loop through icon holders and set selected value for( var y = 1; y <= 3; y++ ) { // if selected set class name else remove if ( y == player_current ) { player_info[ y ].className = "selected"; player_link[ y ].className = "selected"; } else { player_info[ y ].className = ""; player_link[ y ].className = ""; } } if( $( "playerHolder" ) != null ) { scrollPos = (player_current - 1) * 260; $( 'playerHolder' ).scrollTop = scrollPos; } clearTimeout( playersAnim_time ); playersAnim_time = setTimeout( "player_next();", 10 * 1000 ); return false; } function confirmSubmit( message ) { var agree = confirm( message ); if ( agree ) { return true; } else { return false; } } /* LIST ALL GAMES */ //var req = getXMLHttpRequest(); function list_init(languageCountrycode, category) { //category = games, ecards, toons xml_loadXMLDoc('/' + category + '/' + languageCountrycode + '/full_' + category + '_list.php', xml_onReadyStateChange_list); // list_ready(); } function list_ready() { if($('gameList') == null) { return; } if(document.forms['jumpList'] == null) { return; } // list all games menu var games = $('gameList').getElementsByTagName('a'); document.forms['jumpList'].jumpSelect.options[0] = new Option(language[9], ""); var oCount = 1; for( var y = 0; y < games.length; y++ ) { jlText = ""; jlText = games[ y ].innerHTML; jlText = jlText.replace( /&/, "&" ); jlText = jlText.replace( "", "" ); jlText = jlText.replace( "", "" ); jlText = jlText.replace( "", "" ); jlText = jlText.replace(/^\s+|\s+$/g, ''); // trim if( jlText != "" ) { document.forms[ 'jumpList' ].jumpSelect.options[ oCount ] = new Option( jlText, games[ y ].href ); oCount ++; } } document.forms[ 'jumpList' ].jumpSelect.onchange = function() { list_jump(); } // grab cookies var list_display = cookie_read( 'list_display' ); // no cookie so set default if ( list_display == null ) { cookie_create( "list_display", "1", 150 ); list_display = 1; // hidden so hide stuff } else if( list_display == "0" ) { $( 'WrapperComplete' ).className = "hidden"; $( 'listToggle' ).innerHTML = language[ 7 ]; } } // show/ hide the list function list_toggle() { // grab cookies var list_display = cookie_read( 'list_display' ); // currently hidden so show if( list_display == "0" ) { $( 'WrapperComplete' ).className = "shown"; $( 'listToggle' ).innerHTML = language[ 8 ]; cookie_create( "list_display", "1", 150 ); // else hide } else { $( 'WrapperComplete' ).className = "hidden"; $( 'listToggle' ).innerHTML = language[ 7 ]; cookie_create( "list_display", "0", 150 ); } } function list_jump( list ) { if( list == null ) { list = "jumpList"; } var newIndex = document.forms[ list ].jumpSelect.selectedIndex; if ( newIndex != 0 ) { url = document.forms[ list ].jumpSelect.options[ newIndex ].value; top.location = url; } } /* MORE MENU */ var more_displayed = false; function more_display() { if ( more_displayed == true ) { $( 'moreNav' ).className = "hidden"; more_displayed = false; } else { $( 'moreNav' ).className = "shown"; more_displayed = true; } } /* clear current page links */ function clearCurrentLink() { var a = document.getElementsByTagName("A"); for(var i = 0; i < a.length; i++) { if(a[i].href == window.location.href.split("#")[0] || a[i].href == window.location.href.split("?")[0]) { a[i].className = a[i].className + " current"; } } } /* RECENTLY PLAYED */ function recent_save() { // load existing recent games var recentgame = t_gameId; var recentlist = recent_load(); var savedgames = 0; if( recentlist != null ) { var recentArray = recentlist.split( "|" ); // loop through array for( i = 0; i < recentArray.length; i++ ) { // remove duplicates and crop list to recent 6 if ( recentArray[ i ] != t_gameId && savedgames < 5 ) { recentgame = recentgame + "|" + recentArray[ i ]; savedgames ++; } } } // save new list cookie_create( "recent_games", recentgame, 28 ); } function recent_load() { // load recent games into array recentlist = cookie_read( "recent_games" ); return recentlist; } function recent_write() { var mg_latest = $( "mg_latest" ); if( mg_latest == null ) { return; } var recentlist = recent_load(); var outputHTML = ""; } else { outputHTML = language[ 4 ]; } mg_latest.innerHTML = outputHTML; } /* set homepage for IE */ function SetHomepage() { return; var monkey = new Array(); monkey['img'] = 'ieHomepage_monkey.png'; monkey['url'] = 'javascript:history.go(0);'; monkey['onclick'] = 'onClick="SetHomepageAction(this)"'; monkey['alt'] = 'Set aeats.com as your homepage'; // var petOne = new Array(); // petOne['img'] = 'homepagePetsPush01.jpg'; // petOne['url'] = '/players/en/create-your-yome.php'; // petOne['onclick'] = ''; // petOne['alt'] = 'Adopt a pet now!'; // var petTwo = new Array(); // petTwo['img'] = 'homepagePetsPush02.jpg'; // petTwo['url'] = '/players/en/create-your-yome.php'; // petTwo['onclick'] = ''; // petTwo['alt'] = 'Adopt a pet now!'; var sketchstarPush = new Array(); sketchstarPush['img'] = 'homepage-banner-topright_play.png'; sketchstarPush['url'] = '/sketch-star/'; sketchstarPush['onclick'] = ''; sketchstarPush['alt'] = 'Create Free Animations! Play Sketch Star »'; var randArray = new Array(); // randArray[0] = petOne; // randArray[1] = petTwo; randArray[0] = sketchstarPush; if(document.all && cookie_read('homepageSet') != 'cookieset') { randArray[2] = monkey; } var randResult = Math.floor(Math.random() * randArray.length); var randShow = randArray[randResult]; document.write('' + randShow['alt'] + ''); } function SetHomepageAction(object) { document.body.style.behavior="url(#default#homepage)"; document.body.setHomePage("http://www.aeats.com/"); cookie_create("homepageSet", "cookieset", 365); statTracker("/click/setHomepage"); } /* COOKIES */ function cookie_create(name, value, days) { if(days) { var date = new Date(); date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000)); var expires = "; expires=" + date.toGMTString(); } else { var expires = ""; } document.cookie = name + "=" + value + expires + "; path=/"; } function cookie_read(name) { var nameEQ = name + "="; var ca = document.cookie.split(';'); for(var i = 0; i < ca.length; i++) { var c = ca[i]; while (c.charAt(0) == ' ') c = c.substring(1, c.length); if (c.indexOf(nameEQ) == 0 ) return c.substring(nameEQ.length, c.length); } return ""; } function cookie_erase(name) { createCookie(name, "", -1); } /* CLIPBOARD (IE only - need to add mozilla version) */ function cb_init() { // check we're not in MSIE if ( navigator.appName != "Microsoft Internet Explorer" ) { // grab all the divs var divs = document.getElementsByTagName( "div" ); // if a copy div replace content for( var i = 0; i < divs.length; i++ ) { var div = divs[ i ]; // hide unusable buttons if ( div.className == "copyButton" ) { div.innerHTML = language[ 6 ]; } } } } function cb_copy(item) { copied = item.createTextRange(); item.focus(); item.select(); copied.execCommand("Copy"); } /* GENERIC STUFF */ function addLoadEvent(func) { var oldonload = window.onload; if (typeof window.onload != 'function') { window.onload = func; } else { window.onload = function() { oldonload(); func(); } } } function writeEmail(name, display_name) { address = name + "@" + "aeats.com"; if (display_name == null) { document.write("" + address + ""); } else { document.write("" + display_name + ""); } } function prerollCreateGame(pr_gamename, pr_gamewidth, pr_gameheight) { // -------------------------------------------------------------------- // create the code for a flash game, simple function that can be reused // -------------------------------------------------------------------- str_return = ""; str_return = str_return + ""; str_return = str_return + ""; str_return = str_return + ""; str_return = str_return + ""; str_return = str_return + ""; $("video_ad").innerHTML = str_return; } var BrowserDetect = { init: function () { this.OS = this.searchString(this.dataOS) || "an unknown OS"; }, searchString: function (data) { for (var i=0;i"; outputHtml = outputHtml + "#sidebarBoxBackground {display:none;}"; outputHtml = outputHtml + "#sidebarBoxForeground {display:none;}"; outputHtml = outputHtml + "#sideBar {margin-top:-5px;}"; outputHtml = outputHtml + ""; document.write(outputHtml); addLoadEvent(removeSidebarBoxAdComplete); } function removeSidebarBoxAdComplete() { if($("sidebarBoxBackground") != null) { $("sidebarBoxBackground").innerHTML = ""; } if($("sidebarBoxForeground") != null) { $("sidebarBoxForeground").innerHTML = ""; } } function insertHomepageVideo( htmlCode ) { $("homepageVideoInsert").innerHTML = htmlCode; $("homepageVideoInsert").style.display = "block"; } function removeHomepageVideo() { $("homepageVideoInsert").innerHTML = ""; $("homepageVideoInsert").style.display = "none"; } function resizeFrame( f ) { $( f ).style.height = "50px"; url = $( f ).contentWindow.location.href; if(url.indexOf("aeats.com") > 0) { $( f ).style.height = $( f ).contentWindow.document.body.scrollHeight + "px"; } else { $( f ).style.height = "500px"; } } var shockwaveInstalled = null; var shockwaveFirstTime = true; var shockwaveTimeout = null; function shockwaveIsInstalled() { var tVersionString = "0"; if (navigator.mimeTypes && navigator.mimeTypes["application/x-director"] && navigator.mimeTypes["application/x-director"].enabledPlugin) { if (navigator.plugins && navigator.plugins["Shockwave for Director"] && (tVersionIndex = navigator.plugins["Shockwave for Director"].description.indexOf(".")) != - 1) { tVersionString = navigator.plugins["Shockwave for Director"].description.substring(tVersionIndex-2, tVersionIndex+2); } } else if(navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0) { try { var obj = new ActiveXObject("SWCtl.SWCtl"); if(obj != null) { tVersionString = obj.ShockwaveVersion(""); } } catch(e) { } if(obj != null) { delete obj; } } if(parseInt(tVersionString) >= 11) { shockwaveInstalled = true; } else { shockwaveInstalled = false; } return shockwaveInstalled; } function shockwaveInstall() { var showGoldBar = true; if(shockwaveIsInstalled()) { // track new installs if(shockwaveFirstTime == false || cookie_read("sw") == 1) { statPageview("/sw/newInstall"); cookie_erase("sw"); } // track total users with install statTracker("/sw/installed"); // hide installation messaging $("shockwaveGameContainer").style.display = "block"; $("shockwaveInstallWrapper").style.display = "none"; $("shockwaveInstallBar").style.display = "none"; $("blackOverlay").style.display = "none"; $("shockwaveInstallBar").innerHTML = ""; } else { // track not installed if(shockwaveFirstTime == true) { statPageview("/sw/notInstalled"); cookie_create("sw", "1", 10); } var goldbarMessage = "

Adobe Shockwave Required

Installing is easy. When you see the yellow bar above, follow these steps »

"; // if firefox or similar if(navigator.appName == "Netscape") { // if version 3 if(navigator.userAgent.indexOf("Firefox/3") >= 0) { goldbarMessage = goldbarMessage + "

Click Install Missing Plugins

Follow the instructions

Restart Firefox to finish

"; // other versions } else { showGoldBar = false; } } else { goldbarMessage = goldbarMessage + "

Click the Yellow bar above

Choose Install ActiveX Control

Click Install when prompted

"; } goldbarMessage = goldbarMessage + "
"; if(showGoldBar == true) { $("shockwaveGameContainer").style.display = "none"; $("shockwaveInstallWrapper").style.display = "block"; $("shockwaveInstallBar").style.display = "block"; $("blackOverlay").style.display = "block"; $("shockwaveInstallBar").innerHTML = goldbarMessage; } shockwaveTimeout = setTimeout("shockwaveInstall()", 4 * 1000); } shockwaveFirstTime = false; } function LoginBoxNotification(action){ switch(action){ case 'user_logged_in': case 'user_logged_out': from = urlParam('from'); challenge_uid = urlParam('challenge_uid'); challenge_url = decodeURIComponent(urlParam('challenge_url')); redirect_url = ''; if (from == 'challenge') { redirect_url = challenge_url + '?challenge=' + challenge_uid + '&from=' + from; } if (redirect_url != '') { window.location.href = redirect_url; } else { window.location.reload(); } } } function urlParam (name) { name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]"); var regexS = "[\\?&]"+name+"=([^&#]*)"; var regex = new RegExp( regexS ); var results = regex.exec( window.location.href ); if( results == null ) { return ""; } else { return results[1]; } } function statTracker(path) { if (typeof(_gaq) != 'undefined') { _gaq.push(['b._trackPageview', path]); } } function adTracker() { if (document.location.protocol != 'https:') { tracker = new Image(); tracker.src = 'clubpenguintracking/142334@x01'; } } function jsDebug(data) { outputHtml = ""; outputHtml = outputHtml + "
"; outputHtml = outputHtml + data; outputHtml = outputHtml + "
"; $("jsDebugDataBox").innerHTML = $("jsDebugDataBox").innerHTML + outputHtml; } var hpto = new Object; var toolbarHomepageTakeover = false; var hptoDisplay = false; function runTakeover(hpto) { if (hptoDisplay == true) { return; } // --------- // banner ad // --------- if (hpto.MpuURL != undefined) { hpto_MPU_URL = hpto.MpuURL; if (hpto.ClickURL != undefined) { hpto_MPU_URL = hpto_MPU_URL + '?clickTag=' + encodeURIComponent(hpto.ClickURL.replace('[timestamp]', ord)); } takeoverEmbed = ''; if ($('takeoverMPU') != null) { $('takeoverMPU').innerHTML = takeoverEmbed; } else { document.write(takeoverEmbed); } } // ---- // skin // ---- if (hpto.ImageURL_1 == undefined) { hpto_ImageURL_1 = hpto.ImageURL; } else { hpto_ImageURL_1 = hpto.ImageURL_1; } // Set defaults and fallbacks if ( hpto_ImageURL_1 != "" ) { hpto_Image_1 = 'url(' + hpto_ImageURL_1 + ') no-repeat center top !important'; } else { hpto_Image_1 = ''; } if (hpto.Colour == '') { hpto.Colour = '#333333'; } // Define header options switch(hpto.Header) { case 1: headerHeight = 35; break; case 2: headerHeight = 65; break; case 3: headerHeight = 105; break; default: headerHeight = 0; } // Set wrapper/logo visibility if (hpto.Wrapper == true) { $('wrapper').style.marginTop = headerHeight + 'px'; hpto.hpto_Logo = 'h1 a, h1 a:hover, h1 { background:url( /images/bg_h1.png ) no-repeat 12px 10px; }'; } else { $('wrapper').style.background = 'none'; $('wrapper').style.padding = headerHeight + 'px 0 0 0'; if ( hpto.hpto_Logo == false ) { hpto.hpto_Logo = 'h1, h1 a, h1 a:hover { background: none; }'; } else { hpto.hpto_Logo = 'h1, h1 a, h1 a:hover { background: url( /images/takeovers/takeoverLogo.png ) no-repeat 12px 10px; }'; } // adjust tabs if ($('wrapper') != null) { $('wrapper').style.paddingTop = String(headerHeight).concat('px'); } } if ($("toolbarPush")) { $("toolbarPush").innerHTML = ''; } toolbarHomepageTakeover = true; document.body.style.marginRight = ''; // Clickable Takeover if (hpto.bgClickURL !== undefined) { bgClickURL = hpto.bgClickURL; noBubble = false; document.body.onclick = function() { if (noBubble == false) { location.href = bgClickURL; } noBubble = false; } $('wrapper').onclick = function() { noBubble = true; }; $('footer').onclick = function() { noBubble = true; }; document.body.style.cursor = 'pointer'; $('wrapper').style.cursor = 'default'; $('footer').style.cursor = 'default'; } else { document.body.onclick = null; } // Build the Takeover document.body.style.backgroundColor = hpto.Colour; document.body.style.backgroundImage = 'url(' + hpto_ImageURL_1 + ')'; document.body.style.backgroundRepeat = 'no-repeat'; document.body.style.backgroundPosition = 'top center'; if($('beta') != null) { $('beta').style.display = 'none'; } hideMonkey(); document.write(''); // ------ // footer // ------ if (hpto.FootURL != undefined) { if (hpto.FootURL.length > 0) { var hpto_FootImg = new Image(); hpto_FootImg.src = hpto.FootURL; $('footerTakeover').innerHTML = ''; } } // ----- // stats // ----- // Get statistics variables from array hpto_Agency = hpto.Agency; hpto_Client = hpto.Client; hpto_Campaign = hpto.Campaign; // If blank, set unknown. if(hpto_Agency == undefined) { hpto_Agency = "unknown"; } if(hpto_Client == undefined) { hpto_Client = "unknown"; } if(hpto_Campaign == undefined) { hpto_Campaign = "unknown"; } // tracking if (hpto.TrackURL != undefined) { hpto.TrackURL = hpto.TrackURL.replace('[timestamp]', ord); tracker = new Image(); tracker.src = hpto.TrackURL; } hptoDisplay = true; // Log takeover view to Google Analytics trackHPTO(); hpto = new Object(); } function trackHPTO(args) { // Get statistics variables from array hpto_Agency = hpto.Agency; hpto_Client = hpto.Client; hpto_Campaign = hpto.Campaign; // If blank, set unknown. if(hpto_Agency == undefined) { hpto_Agency = "unknown"; } if(hpto_Client == undefined) { hpto_Client = "unknown"; } if(hpto_Campaign == undefined) { hpto_Campaign = "unknown"; } if (args == undefined) { args = ''; } var path = '/takeovers/' + encodeURI(hpto_Agency.replace(' ', '-')) + '/' + encodeURI(hpto_Client.replace(' ', '-')) + '/' + encodeURI(hpto_Campaign.replace(' ', '-')) + args; statTracker(path); } var isInternetExplorer = navigator.appName.indexOf("Microsoft") != -1; // Handle all the FSCommand messages in a Flash movie. function Ad_that_changes_background_AS1_DoFSCommand(command, args) { var Ad_that_changes_background_AS1Obj = isInternetExplorer ? document.all.Ad_that_changes_background_AS1 : document.Ad_that_changes_background_AS1; imagePath = hpto['ImageURL_' + args]; if (imagePath == undefined) { imagePath = hpto.ImageURL; } bgColor = hpto['Colour_' + args]; if (bgColor == undefined) { bgColor = hpto.Colour; } document.body.style.backgroundImage = 'url(' + imagePath + ')'; document.body.style.backgroundColor = bgColor; trackHPTO('/swapBackground/' + args); } // Hook for Internet Explorer. if (navigator.appName && navigator.appName.indexOf("Microsoft") != -1 && navigator.userAgent.indexOf("Windows") != -1 && navigator.userAgent.indexOf("Windows 3.1") == -1) { document.write('