﻿function submitForm() {
    document.searchform.submit();
}
function myEriksLogin() {
    document.getElementById('callbackbox').style.display = "none";
    document.getElementById('callbacktop').style.backgroundColor = "#006cb7";
    if (document.getElementById('myeriksbox').style.display == "none" || document.getElementById('myeriksbox').style.display == "") {
        document.getElementById('myeriksbox').style.display = "block";
        document.getElementById('myerikstop').style.backgroundColor = "#45c5f2";
    }
    else {
        document.getElementById('myerikstop').style.backgroundColor = "#006cb7";
        document.getElementById('myeriksbox').style.display = "none";
    }
}
function callbackRequest() {
    document.getElementById('myeriksbox').style.display = "none";
    document.getElementById('myerikstop').style.backgroundColor = "#006cb7";
    if (document.getElementById('callbackbox').style.display == "none" || document.getElementById('callbackbox').style.display == "") {
        document.getElementById('callbackbox').style.display = "block";
        document.getElementById('callbacktop').style.backgroundColor = "#45c5f2";
    }
    else {
        document.getElementById('callbackbox').style.display = "none";
        document.getElementById('callbacktop').style.backgroundColor = "#006cb7";
    }
}
function getRequestObj() {
    try { return new ActiveXObject("Msxml2.XMLHTTP.6.0"); }
    catch (e) { }
    try { return new ActiveXObject("Msxml2.XMLHTTP.3.0"); }
    catch (e) { }
    try { return new ActiveXObject("Microsoft.XMLHTTP"); }
    catch (e) { }
    //Microsoft.XMLHTTP points to Msxml2.XMLHTTP and is redundant
    throw new Error("This browser does not support XMLHttpRequest.");
}
function tbc(pid, bid) {
    var oReq = new Object();
    if (typeof XMLHttpRequest != "undefined") {
        oReq = new XMLHttpRequest();
    } else {
        try { oReq = getRequestObj(); }
        catch (e) { return void (0); }
    }
    var sUrl = "/tbc.aspx?pid=" + pid + "&bid=" + bid + "&rand=" + Math.floor(Math.random() * 1001);
    oReq.open("GET", sUrl, true);
    oReq.send(null);
    return void (0);
}
