

var mboxCopyright = "Copyright 2003-2005 Offermatica Corporation. All Rights Reserved. This software is the proprietary information of Offermatica Corporation. Use is subject to license terms.";


if (typeof mboxIncluded == 'undefined') {
 var mboxIncluded = true;
 var mboxVersion = 17;

 var mboxClientCode = 'zaazalcoa';
 var mboxServerURL = 'http://mbox2.offermatica.com/m2/zaazalcoa/mbox/standard';

 var mboxTrafficDuration = 10368000;

 if (typeof mboxPCIdExpireTime == 'undefined') {
 
 
 var mboxPCIdExpireTime = 2 * 365 * 24 * 60 * 60;
 }
 
 
 function mboxCookiePageDomain() {
 var l0 = document.location.host;
 var e1 = /[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/;
 if (!e1.exec(document.location.host)) {
 var w2 = /[^\.]+\.[^\.]+$/;
 var o3 = w2.exec(document.location.hostname);
 if (o3) {
 l0 = o3[0];
 }
 }
 return l0;
 }
 var mboxCookies = new mboxCookieManager("mbox", mboxCookiePageDomain());
 
 var mboxSessionIdCookie = "session";
 var mboxPCIdCookie = "PC";
 var mboxDisableCookie = "disable";
 var mboxCheckCookie = "check";
 var mboxDebugModeCookie = "debug";
 var mboxTrafficLevelCookie="level";
 var mboxTrafficStateCookie="traffic";

 var mboxXDomainArg = "mboxXDomain";

 var mboxNameArg = "mbox";
 var mboxClientCodeArg = "mboxClient";
 var mboxPCIdArg = "mboxPC";
 var mboxSessionIdArg = "mboxSession";
 var mboxFirstPageInVisitArg = "mboxFirstPageInVisit";
 var mboxPageIdArg = "mboxPage";
 var mboxHostArg = "mboxHost";
 var mboxURLArg = "mboxURL";
 var mboxReferrerArg = "mboxReferrer";
 var mboxVersionArg = "mboxVersion";
 var mboxCountArg = "mboxCount";
 var mboxEnvironmentArg = "envId";
 var mboxMarkerDivPrefix = "mboxMarker-";
 var mboxImportDivPrefix = "mboxImported-";
 var mboxDefaultDivClass = "mboxDefault";
 var mboxSignalPrefix = "signal-";

 var mboxPageId = mboxGenerateId();
 var mboxSessionId = new mboxSession(mboxPageId, mboxSessionIdArg,
 mboxSessionIdCookie, 31 * 60);
 var mboxPCId = new mboxPC(mboxPageId, mboxPCIdCookie, mboxPCIdExpireTime);

 var mboxs = new Object(); 
 var mboxGlobalArguments = "";
 var mboxCount = 0; 
 var mboxSignalCount = 0;

 var mboxCampaignsStateVersion = 0;
 var mboxCampaigns = new Array();

 var mboxEnv = new mboxEnvironment("mboxDisable");

 var pageLoadStartTime = new Date().getTime();
 var pageLoadEndTime = pageLoadStartTime;
 mboxEnv.getSafeBodyOnload().add(
 new Function("pageLoadEndTime = new Date().getTime()"));

 var mboxDebugInfo = new mboxDebug(mboxDebugModeCookie, "mboxDebug", mboxEnv);

 if (mboxEnv.platform.isSupported()) {
 mboxEnv.getSafeBodyOnload().add(mboxCheckAll);

 mboxEnv.limitTraffic(100, 10368000);

 if (mboxEnv.isEnabled()) {
 mboxSignal();
 mboxDefaultContentDisplayNone();
 }
 else {
 
 }
 } 
}



function mboxCreate(u4 ) {
 if (!mboxEnv.platform.isSupported()) {
 return;
 }
 mboxEnv.getSafeBodyOnload().setup();

 var m5 = new Array();
 m5[0] = mboxNameArg + '=' + u4;
 for (var i = 1; i < arguments.length; i++) {
 m5[i] = arguments[i];
 }

 var q6 = new mbox(u4, m5);
 q6.put();
}


function mboxGlobalParameters() {
 for (var t7 = 0; t7 < arguments.length; t7++) {
 if (mboxGlobalArguments != "") {
 mboxGlobalArguments = mboxGlobalArguments + "&";
 } 
 mboxGlobalArguments = mboxGlobalArguments + arguments[t7];
 }
}


function mboxBase(c8, b9) {
 this.id = c8;
 this.url = b9;
 this.timeout = null;
 this.activated = 0;
 this.defaultDiv = null;

 this.offer = new mboxOfferContent();

 this.put = mbox_put;
 this.show = mbox_show;
 this.showContent = mbox_showContent;
 this.hide = mbox_hide;
 this.startTimeout = mbox_startTimeout;
 this.cancelTimeout = mbox_cancelTimeout;
 this.getDefaultDiv = mbox_getDefaultDiv;
 this.activate = mbox_activate;
 this.isActivated = mbox_isActivated;
 this.markerName = mbox_markerName;
 this.importName = mbox_importName;
 this.importDiv = mbox_getImportDiv;
 this.finalize = mbox_finalize;
 this.parameters = mbox_getParams;

 this.activateAction = mbox_show;
 this.setActivateAction = mbox_setActivateAction;
 this.setOffer = mbox_setOffer;

 this.time = new Object();
 this.activateCount = 0;
 this.setEventTime = mbox_setEventTime;


 this.error = null;

 if (mboxs[c8]) {
 this.error = "multiple mboxes with the id '" + c8 + "' exist on this page";
 this.put = mbox_putNothing;
 this.activateAction = mbox_hide;
 }

 mboxs[c8] = this;
}

function mbox(c8, m5) {
 this.base = mboxBase;
 m5[m5.length] = mboxCountArg + "=" + ++mboxCount;
 this.base(c8, mboxBuildURL(m5));
}

function mboxSignalMbox(c8, m5) {
 this.base = mboxBase;
 m5[m5.length] = mboxCountArg + "=" + --mboxSignalCount;
 this.base(c8, mboxBuildURL(m5));
}


function mbox_getParams() {
 return mboxGetParamsFromQueryString(this.url);
}

function mboxGetParamsFromQueryString(url) {
 var parameters = new Object();

 var position = url.indexOf("?");
 if (position == -1 || position == (url.length - 1)) {
 return parameters;
 }

 var queryString = url.substring(position + 1);
 var pairs = queryString.split("&");
 for (var i = 0; i < pairs.length; i++) {
 var pair = pairs[i].split("=");
 if (pair.length < 2 || pair[0] == "" || pair[1] == "") {
 continue;
 } else {
 parameters[pair[0]] = pair[1];
 }
 }

 return parameters;
}


function mbox_put() {
 if (mboxEnv.isEnabled()) {
 this.setEventTime("put.start");
 document.write(
 '<div id="' + this.markerName()
 + '" style="visibility:hidden;display:none">'
 + '<script language="JavaScript">'
 + 'mboxs["' + this.id + '"].startTimeout(15000);'
 + '<' + '\/script>'
 + '<script src="' + this.url + '" language="JavaScript"><'+ '\/script>'
 + '</div>');

 this.setEventTime("put.end");
 }
 else {
 document.write('<div id="' + this.markerName() + '"></div>');
 }
}

function mbox_putNothing() {
 document.write('<div id="' + this.markerName() + '"></div>');
}


function mbox_activate() {
 if (this.activated) {
 return this.activated;
 }
 this.setEventTime('activate' + ++this.activateCount + '.start');

 if (this.activateAction()) {
 this.cancelTimeout();
 this.activated = 1;
 }

 this.setEventTime('activate' + this.activateCount + '.end');
 return this.activated;
}


function mbox_isActivated() {
 return this.activated;
}


function mbox_setActivateAction(e10) {
 this.activateAction = e10;
}


function mbox_setOffer(q11) {
 this.offer = q11;
}


function mbox_show() {
 this.setEventTime('show.start');

 var result = this.offer.show(this);

 this.setEventTime(result == 1 ? "show.end.ok" : "show.end");

 return result;
}


function mbox_showContent(c12) {
 
 if (c12 == null) {
 return 0;
 }

 var r13 = this.getDefaultDiv();

 if (mboxEnv.platform.supportsReplace()) {
 if (r13 != null) {
 r13.parentNode.replaceChild(c12, r13);
 }
 
 
 else {
 var r14 = document.getElementById(this.markerName());

 
 if (r14 == null) {
 return 0;
 }

 mboxMakeDivVisible(r14);
 }
 }
 
 
 else {
 var r14 = document.getElementById(this.markerName());

 
 if (r14 == null) {
 return 0;
 }

 if (r13 != null) {
 mboxMakeDivInvisible(r13);
 }

 mboxMakeDivVisible(r14);
 }

 mboxMakeDivVisible(c12);

 
 
 return 1;
}

function mboxMakeDivVisible(t15) {
 t15.style.visibility = "visible";
 t15.style.display = "block";
}

function mboxMakeDivInvisible(t15) {
 t15.style.visibility = "hidden";
 t15.style.display = "none";
}


function mbox_hide() {
 this.setEventTime('hide.start');

 var r14 = document.getElementById(this.markerName());
 if (r14 != null) {
 r14.style.visibility = "hidden";
 r14.style.display = "none";
 }

 var r13 = this.getDefaultDiv();

 if (r13 != null) {
 r13.style.visibility = "visible";
 r13.style.display = "block";

 this.setEventTime('hide.end.ok');

 return 1;
 }

 this.setEventTime('hide.end.fail');

 return 0;
}


function mbox_finalize() {
 this.setEventTime('finalize.start');

 this.cancelTimeout();

 if (!this.activate()) {
 this.hide();

 this.setEventTime('finalize.end.hide');
 }

 this.setEventTime('finalize.end.ok');
}

function mbox_startTimeout(s16) {
 this.timeout =
 setTimeout('mboxCheckTimeoutById("' + this.id + '")', s16);
}

function mbox_cancelTimeout() {
 if (this.timeout != null) {
 clearTimeout(this.timeout);
 }
}

function mbox_getImportDiv() {
 return document.getElementById(this.importName());
}

function mbox_getDefaultDiv() {
 if (this.defaultDiv != null) {
 return this.defaultDiv;
 }

 var node = document.getElementById(this.markerName());
 while (node != null) {
 
 if ((node.nodeType == 1) && (node.nodeName == "DIV")) {
 if (node.className.indexOf(mboxMarkerDivPrefix) > 0) {
 return null;
 } else if (node.className == mboxDefaultDivClass) {
 this.defaultDiv = node;

 return node;
 }
 }
 node = node.previousSibling;
 }

 return null;
}


function mbox_setActivateAction(action) {
 this.activateAction = action;
}

function mbox_markerName() {
 return mboxMarkerDivPrefix + this.id
}

function mbox_importName() {
 return mboxImportDivPrefix + this.id
}

function mbox_setEventTime(event) {
 this.time[event] = (new Date()).getTime();
}

function mboxOfferContent() {
 this.show = mboxOfferContent_show;
}

function mboxOfferContent_show(w17) {
 var c12 = w17.importDiv();

 return w17.showContent(c12);
}

function mboxOfferDefault() {
 this.show = mboxOfferDefault_show;
}

function mboxOfferDefault_show(w17) {
 return w17.hide();
}


function mboxBuildURL(m5) {
 var k18 = mboxServerURL;

 if (document.location.protocol == "https:") {
 k18 = k18.replace("http:", "https:")
 }
 k18 += "?" + mboxHostArg + "=" + document.location.hostname;

 for (var t7 = 0; t7 < m5.length; t7++) {
 k18 += "&" + m5[t7];
 }

 if (mboxGlobalArguments.length > 0) {
 k18 += "&" + mboxGlobalArguments;
 }

 if (k18.indexOf(mboxSessionIdArg) == -1) {
 k18 += "&" + mboxSessionIdArg + "=" + mboxSessionId.getId();
 }

 if (mboxSessionId.isNew()) {
 k18 += "&" + mboxFirstPageInVisitArg + "=" + true;
 }

 k18 = k18 + "&" + mboxPCIdArg + "=" + mboxPCId.getId()
 + "&" + mboxPageIdArg + "=" + mboxPageId
 
 + "&" + mboxURLArg + "=" + escape(document.location);

 var y19 = escape(document.referrer);
 if (k18.length + y19.length < 2000) {
 k18 += "&" + mboxReferrerArg + "=" + y19
 }

 return k18 + "&" + mboxVersionArg + "=" + mboxVersion;
}


function mboxEnvironment(d20) {
 this.platform = new mboxPlatform();
 this.s21 = null;

 this.l22 = this.platform.isSupported();

 if (mboxGetPageParameter(d20) != null) {
 this.l22 = false;
 }

 
 
 if (!mboxCookies.isEnabled()) {
 this.l22 = false;
 }
 if (mboxCookies.getCookie(mboxDisableCookie) == "true") {
 this.l22 = false;
 }
 

 this.isEnabled = mboxEnvironment_isEnabled;
 this.disable = mboxEnvironment_disable;
 this.enable = mboxEnvironment_enable;
 this.isAdmin = mboxEnvironment_isAdmin;
 this.limitTraffic = mboxEnvironment_limitTraffic;
 this.getSafeBodyOnload = mboxEnvironment_getSafeBodyOnload;

 if (this.isAdmin()) {
 this.enable();
 }
}

function mboxEnvironment_isEnabled() {
 return this.l22;
}

function mboxEnvironment_getSafeBodyOnload() {
 if (this.s21 == null) {
 this.s21 = new mboxSafeOnload(window);
 }

 return this.s21;
}

function mboxEnvironment_disable(duration) {
 if (typeof duration == 'undefined') {
 duration = 60 * 60;
 }
 if (!this.isAdmin()) {
 this.l22 = false;
 mboxCookies.setCookie(mboxDisableCookie, "true", duration);
 }
}

function mboxEnvironment_enable() {
 this.l22 = true;
 mboxCookies.deleteCookie(mboxDisableCookie);
}

function mboxEnvironment_isAdmin() {
 return document.location.href.indexOf(mboxEnvironmentArg) != -1;
}

function mboxEnvironment_limitTraffic(level, duration) {
 if (level == 100) {
 return;
 }

 var e23 = mboxCookies.getCookie(mboxTrafficStateCookie);

 if (this.isAdmin()) {
 e23 = true;
 mboxCookies.setCookie(mboxTrafficLevelCookie, level, duration);
 mboxCookies.setCookie(mboxTrafficStateCookie, e23, duration);
 }
 else if (e23 == null || mboxCookies.getCookie(mboxTrafficLevelCookie) != level) {
 e23 = (Math.random() * 100) <= level;
 mboxCookies.setCookie(mboxTrafficLevelCookie, level, duration);
 mboxCookies.setCookie(mboxTrafficStateCookie, e23, duration);
 }

 if (e23) {
 this.enable();
 }
 else {
 this.disable();
 }
}

function mboxCookieManager(y24, l0) {
 this.name = y24;

 if (l0.indexOf(".") == -1) {
 
 l0 = "";
 }

 this.domain = l0 == "" ? "" : "; domain=" + l0;

 this.isEnabled = mboxCookieManager_isEnabled;
 this.getCookie = mboxCookieManager_getCookie;
 this.setCookie = mboxCookieManager_setCookie;
 this.deleteCookie = mboxCookieManager_deleteCookie;
 this.getCookieNames = mboxCookieManager_getCookieNames;
 this.loadCookies = mboxCookieManager_loadCookies;
 this.saveCookies = mboxCookieManager_saveCookies;

 this.loadCookies();
}

function mboxCookieManager_isEnabled() {
 this.setCookie(mboxCheckCookie, "true", 60);
 this.loadCookies()
 return this.getCookie(mboxCheckCookie) == "true";
}



function mboxCookieManager_setCookie(y24, i25, s16) {
 if (typeof y24 != 'undefined' &&
 typeof i25 != 'undefined' &&
 typeof s16 != 'undefined') {

 this.cookies[y24] = {
 name:y24,
 value:escape(i25),
 
 expireOn:Math.ceil(s16 + new Date().getTime() / 1000)
 }
 this.saveCookies();
 }
}

function mboxCookieManager_getCookie(y24) {
 var f26 = this.cookies[y24];
 if (typeof f26 == 'undefined' || f26 == null) {
 return null;
 }
 return unescape(f26.value);
}

function mboxCookieManager_deleteCookie(y24) {
 var f27 = new Object();
 for (f26 in this.cookies) {
 if (f26 != y24) {
 f27[f26] = this.cookies[f26];
 }
 }
 this.cookies = f27;
 this.saveCookies();
}

function mboxCookieManager_getCookieNames(f28) {
 var s29 = new Object();
 for (f26 in this.cookies) {
 if (f26.indexOf(f28) == 0) {
 s29[s29.length] = f26;
 }
 }
 return s29;
}

function mboxCookieManager_loadCookies() {
 this.cookies = new Object();
 var k30 = document.cookie.indexOf(this.name + "=");
 if (k30 != -1) {
 var p31 = document.cookie.indexOf(";", k30);
 if (p31 == -1) {
 p31 = document.cookie.indexOf(",", k30);
 if (p31 == -1) {
 p31 = document.cookie.length;
 }
 }

 var q32 = document.cookie.substring(
 k30 + this.name.length + 1, p31).split("|");

 var h33 = Math.ceil(new Date().getTime() / 1000);
 for (var i = 0; i < q32.length; i++) {
 var f26 = q32[i].split("#");
 if (h33 <= f26[2]) {
 this.cookies[f26[0]] =
 {name:f26[0], value:f26[1], expireOn:f26[2]}
 }
 }
 }
}

function mboxCookieManager_saveCookies() {

 var q34 = new Array();
 var u35 = 0;
 for (f26 in this.cookies) {
 if (this.cookies[f26] != null) {
 q34[q34.length] = this.cookies[f26].name + "#" +
 this.cookies[f26].value + "#" + this.cookies[f26].expireOn;

 if (u35 < this.cookies[f26].expireOn) {
 u35 = this.cookies[f26].expireOn;
 }
 }
 }

 var h36 = new Date(u35 * 1000);
 document.cookie = this.name + "=" + q34.join("|")
 + "; expires=" + h36.toGMTString() + "; path=/" + this.domain;

}

function mboxTimedOut() {
 return mboxCookies.getCookie(mboxDisableCookie) == "true";
}

function mboxCancelTimeoutById(id) {
 mboxActivateById(id);
}

function mboxActivateById(id) {
 mboxs[id].activate();
}

function mboxCheckTimeoutById(id) {
 mboxActivateById(id);

 if (!mboxs[id].isActivated()) {
 mboxEnv.disable();
 
 window.location.reload(false);
 }
}


function mboxCheckAll() {
 for (var mbox in mboxs) {
 mboxs[mbox].finalize();
 }
}


function mboxGetDefaultDiv(u4) {
 return mboxs[u4].getDefaultDiv();
}


function mboxMarkerName(u4) {
 return mboxs[u4].markerName();
}


function mboxImportName(u4) {
 return mboxs[u4].importName();
}


function mboxSetupSignal(k37, u4 ) {
 var m5 = new Array();
 for (var i = 1; i < arguments.length; i++) {
 m5[i-1] = arguments[i];
 }
 mboxCookies.setCookie(mboxSignalPrefix + k37, m5.join("&"), 45 * 60);
}


function mboxSignal() {
 var t38 = mboxCookies.getCookieNames(mboxSignalPrefix);
 for (f39 in t38) {
 var v40 = mboxCookies.getCookie(t38[f39]);
 var m5 = v40.split("&");
 var u4 = m5[0];
 m5[0] = mboxNameArg + '=' + u4;
 var n41 = new mboxSignalMbox(u4, m5);
 n41.put();
 mboxCookies.deleteCookie(t38[f39]);
 }
}


function mboxDefaultContentDisplayNone() {
 document.write("<style>." + mboxDefaultDivClass
 + " { visibility:hidden; }</style>");
}


function mboxArg(l42, i25) {
 return l42 + "=" + escape(i25);
}


function mboxSession(y43, z44, l45, i46) {
 this.idArg = z44;
 this.cookieName = l45;
 this.expireTime = i46;

 this.newSession = false;

 this.id = mboxGetPageParameter(this.idArg);

 if (this.id == null || this.id.length == 0) {
 this.id = mboxCookies.getCookie(mboxSessionIdCookie);
 if (this.id == null || this.id.length == 0) {
 this.id = y43;
 this.newSession = true;
 }
 }

 mboxSetCookie(mboxSessionIdCookie, this.id, i46);

 this.getId = mboxSession_getId;
 this.isNew = mboxSession_isNew;
 this.reset = mboxSession_reset;
 this.forceId = mboxSession_forceId;
}


function mboxSession_getId() {
 return this.id;
}


function mboxSession_isNew() {
 return this.newSession;
}

function mboxSession_reset() {
 this.id = mboxGenerateId();

 mboxCookies.setCookie(this.cookieName, this.id, this.expireTime);
}

function mboxSession_forceId(forcedId, isNewSession) {
 this.id = forcedId;

 
 
 
 
 
 
 if (typeof isNewSession == 'undefined') {
 if (mboxCookies.getCookie(mboxSessionIdCookie) == forcedId) {
 this.newSession = false;
 } else {
 this.newSession = true;
 }
 } else {
 this.newSession = isNewSession;
 }

 mboxCookies.setCookie(this.cookieName, this.id, this.expireTime);
}


function mboxPC(y43, l45, i46) {
 this.cookieName = l45;
 this.expireTime = i46;

 this.id = mboxCookies.getCookie(this.cookieName);

 if (this.id == null || this.id.length == 0) {
 this.id = y43;
 }

 this.getId = mboxPC_getId;
 this.forceId = mboxPC_forceId;
}


function mboxPC_getId() {
 
 mboxCookies.setCookie(mboxPCIdCookie, this.id, this.expireTime);

 return this.id;
}


function mboxPC_forceId(forcedId) {
 if (this.id != forcedId) {
 this.id = forcedId;

 mboxCookies.setCookie(this.cookieName, this.id, this.expireTime);

 return true;
 }

 return false;
}

function mboxGenerateId() {
 return (new Date()).getTime() + "-" + Math.floor(Math.random() * 999999);
}

function mboxGetPageParameter(name) {
 var k18 = null;

 var v47 = new RegExp(name + "=([^\&]*)");
 var l48 = v47.exec(document.location);
 if (l48 != null && l48.length >=2) {
 k18 = l48[1];
 }

 return k18;
}

function mboxDisplayDebugInfo() {
 mboxDebugInfo.show();
}

function mboxDebug(l49, i50, m51) {
 this.debugCookie = l49;

 this.isEnabled = mboxDebug_isEnabled;
 this.disable = mboxDebug_disable;
 this.show = mboxDebug_show;
 this.setShowAction = mboxDebug_setShowAction;
 this.action = null;

 var l52 = mboxGetPageParameter(i50);
 if (l52 == null) {
 l52 = mboxCookies.getCookie(this.debugCookie);
 }

 if (l52 != null) {
 if (l52.indexOf("x") == 0) {
 
 this.action = new mboxDebugActionNone();

 document.write('<script language="Javascript1.2" src="'
 + 'http://admin2.offermatica.com/admin/mbox/mbox_debug_' + l52 + '.js'
 + '"><' + '\/script>');
 }
 else if (l52.indexOf("log") == 0) {
 this.action = new mboxDebugActionLog(l52);
 }
 else if (l52 == "reset") {
 l52 = null;
 }
 else {
 this.action = new mboxDebugActionDefault();
 }
 }

 if (this.action != null) {
 if (m51.platform.isSupported()) {
 m51.getSafeBodyOnload().sortedAdd(mboxDisplayDebugInfo,
 m51.getSafeBodyOnload().orderLast);
 }
 else {
 alert("mbox functionality is not supported on this browser");
 mboxDebugInfo.disable();
 }
 }

 if (l52 != null) {
 mboxCookies.setCookie(this.debugCookie, l52, 45 * 60);
 }
 else {
 this.disable()
 }
}

function mboxDebug_isEnabled() {
 return this.action != null;
}


function mboxDebug_disable() {
 mboxCookies.deleteCookie(this.debugCookie);
}

function mboxDebug_setShowAction(e10) {
 this.action = e10;
}

function mboxDebug_show() {
 if (this.action != null) {
 this.action.show();
 }
}

function mboxDebugActionLog(mode) {
 this.mode = mode;
 this.start = (new Date()).getTime();

 this.show = mboxDebugActionLog_show;
}

function mboxDebugActionLog_show() {
 var end = (new Date()).getTime();

 var window = new mboxDebugWindow("Debug Log");

 window.putPageStart();
 window.put("<img src='http://mbox2.offermatica.com/admin/images/spacer.gif"
 + "?mboxDebug=" + this.mode
 + "&mboxClient=" + mboxClientCode
 + "&pageLoadTime=" + (end - this.start)
 + "&mboxCount=" + mboxCount
 + "&mboxSignalCount=" + mboxSignalCount + "'>");

 window.put("<br />");

 window.putCloseButton()
 window.putPageEnd();
}


function mboxDebugActionNone() {
 this.show = mboxDebugActionDefault_show;
}

function mboxDebugActionNone_show() {
 alert("mboxDebugAction not defined");
}

function mboxDebugActionDefault() {
 this.show = mboxDebugActionDefault_show;
}

function mboxDebugActionDefault_show() {
 var window = new mboxDebugWindow("Debug");

 window.putPageStart();
 window.put("  <b>Mbox Debug Window (version:" + mboxVersion + ")</b></br>");

 window.put("<p/>");
 window.put("<b>Page</b>: " + document.location);

 window.put(" <ul>");

 if (mboxEnv.isEnabled()) {
 window.put("  <li>Enabled: true</li>");
 } else {
 window.put(
 '  <li>Enabled: <span style="color:red"><b>false</b></span></li>');
 }

 window.put("  <li>Cookies enabled: " + mboxCookieIsEnabled() + "</li>");
 window.put("  <li>Global arguments: '" + mboxGlobalArguments + "'</li>");
 window.put("  <li>Referring URL: '" + document.referrer + "'</li>");
 window.put("  <li>Page URL: '" + document.location + "'</li>");
 window.put("  <li>Cookies: '" + document.cookie + "'</li>");
 window.put("  <li>Page Id: " + mboxPageId + "</li>");

 for (u4 in mboxs) {
 window.put("  <li>mbox: '" + mboxs[u4].id + "'");
 window.put("   <ul>");

 if (mboxs[u4].error) {
 window.put('   <li><span style="color: red"><b>Error: '
 + mboxs[u4].error + '</b></span></li>');
 }

 var r14 = document.getElementById(mboxMarkerName(mboxs[u4].id));
 if (r14 == null) {
 window.put('    <li><span style="color: red">'
 + '<b>Error: can not find mbox in dom</b></span></li>');
 } else {
 window.put("    <li>has mboxDefault content div tags: "
 + (mboxs[u4].defaultDiv != null) + "</li>");
 }

 window.put('    <li><a href="' + mboxs[u4].url + '">'
 + mboxs[u4].url + '</a></li>');

 window.put("   </ul>");
 window.put("  </li>");
 }

 window.put(" </ul>");

 window.putCloseButton()
 window.putPageEnd();
}

function mboxDebugWindow(name) {
 this.y24 = name + " " + document.location.hostname;

 var w53 = /\W/g;
 var t54 = this.y24.replace(w53, '_');

 this.put = mboxDebugWindow_put;
 this.putCloseButton = mboxDebugWindow_putCloseButton;
 this.putPageStart = mboxDebugWindow_putPageStart;
 this.putPageEnd = mboxDebugWindow_putPageEnd;

 this.window = window.open("", "mboxDebugWindow" + t54,
 "width=600,height=300,resizable,scrollbars=yes,toolbar=yes");

 if (this.window == null) {
 alert("Unable to open Offermatica's mboxDebugWindow Window.\n"
 + "Are you blocking popups?\n");
 return;
 }
}


function mboxDebugWindow_put(e56) {
 if (this.window == null) {
 return;
 }
 this.window.document.writeln(e56);
 this.window.scrollBy(0, 1000);
}

function mboxDebugWindow_putCloseButton() {
 this.put("<a href=\"javascript:mboxDebugWindowClose()\">"
 + "click here to close debug window</a>");
}

function mboxDebugWindow_putPageStart() {
 this.put("<html><head>")
 this.put(" <title>" + this.y24 + "</title>");
 this.put("  <script>");
 this.put("   function mboxDebugWindowOnClose() {");
 this.put("       window.opener.mboxDebugInfo.disable();");
 this.put("   }");
 this.put("   ");
 this.put("   function mboxDebugWindowClose() {");
 this.put("     try {");
 this.put("       window.opener.mboxDebugInfo.disable();");
 this.put("     } catch(e) {");
 this.put("       alert('Could not disable debug mode.\\n'");
 this.put("         + 'Browse to a page containing an mbox and\\n'");
 this.put("         + 'click on close link.');");
 this.put("     }");
 this.put("     window.close();");
 this.put("   }");
 this.put("  </" + "script>");
 this.put(" </head>")
 this.put(" <body onunload='mboxDebugWindowOnClose()'>")
}

function mboxDebugWindow_putPageEnd() {
 this.put("</body></html>");

 this.window.document.close();
}

function mboxSafeOnload(element) {
 this.k57 = new Array()

 this.orderFirst = 0;
 this.orderMiddle = 500;
 this.orderLast = 1000;

 this.add = mboxSafeOnload_add;
 this.sortedAdd = mboxSafeOnload_sortedAdd;
 this.setup = mboxSafeOnload_setup;
 this.action = mboxSafeOnload_action;
 this.element = element;
 this.actionStarted = false;

 
 
 
 if (typeof mboxSafeOnloadFunctions == "undefined") {
 mboxSafeOnloadFunctions = new Array();
 }

 
 
 var offset = mboxSafeOnloadFunctions.length;
 mboxSafeOnloadFunctions[offset] = this;
 this.y58 = new Function("event",
 "mboxSafeOnloadFunctions[" + offset + "].action(event)");

 this.setup();
}

function mboxSafeOnload_setup() {
 if (this.element.onload != this.y58) {
 if (this.element.onload) {
 this.add(this.element.onload);
 }

 this.element.onload = this.y58;
 }
}

function mboxSafeOnload_add(b59) {
 this.sortedAdd(b59, this.orderMiddle)
}

function mboxSafeOnload_sortedAdd(b59, k60) {
 var y58 = new Array()
 y58.order = k60;
 y58.action = b59;
 this.k57[this.k57.length] = y58;
}


function mboxSafeOnload_action(y61) {
 if (this.actionStarted == true) {
 return;
 }
 this.actionStarted = true;

 this.k57.sort(mboxSafeOnload_orderSort);

 for (var t7 = 0; t7 < this.k57.length; t7++) {
 
 
 this.element.onload = this.k57[t7].action;
 this.element.onload(y61);
 }
 this.element.onload = this.y58
}

function mboxSafeOnload_orderSort(o62, r63) {
 return o62.order - r63.order;
}


function mboxSetCookie(y24, i25, s16) {
 mboxCookies.setCookie(y24, i25, s16);
}


function mboxGetCookie(y24) {
 return mboxCookies.getCookie(y24);
}


function mboxDeleteCookie(y24) {
 mboxCookies.deleteCookie(y24);
}


function mboxGetCookieNames(f28) {
 return mboxCookies.getCookieNames(f28);
}

function mboxCookieIsEnabled() {
 mboxCookies.setCookie(mboxCheckCookie, "true", 60);
 return mboxCookies.getCookie(mboxCheckCookie) == "true";
}

function mboxIsSupported() {
 return true;
}

function mboxPlatform() {
 this.y64 = window.navigator.appVersion.indexOf("Mac") != -1;
 this.c65 = window.navigator.appVersion.indexOf("MSIE") != -1;

 var n66 = window.navigator.userAgent.indexOf("Opera") != -1;
 var j67 = window.navigator.userAgent.indexOf("Konqueror") != -1;
 var j68 = this.c65 &&
 (window.navigator.appVersion.indexOf("MSIE 4.") != -1);
 var w69 = (navigator.appName == 'Netscape') &&
 (parseInt(navigator.appVersion) == 4);

 this.supported = mboxIsSupported() &&
 !(w69 || j68 || n66 || j67);

 this.isSupported = mboxPlatform_isSupported;
 this.supportsReplace = mboxPlatform_supportsReplace;
}

function mboxPlatform_isSupported() {
 return this.supported;
}

function mboxPlatform_supportsReplace() {
 return !(this.c65 && this.y64)
}


function mboxForcePCId(forcedId) {
 if (mboxPCId.forceId(forcedId)) {
 mboxSessionId.reset();
 }
}


function mboxSetSessionId() {
 mboxSessionId.forceId(arguments[0],arguments[1]);
}


function mboxSafeBodyOnload() {
 if (arguments.length > 1) {
 mboxEnv.getSafeBodyOnload().add(arguments[0], arguments[1]);
 }
 else {
 mboxEnv.getSafeBodyOnload().add(arguments[0]);
 }
}


