//Script File


// Pop Window
function popUpWindow(contentID){
    var page;
    var height;
    var width;
    var winName = contentID;
    var sb = "no";
    switch(contentID)
    {
        case "JHCC":
            page = "http://www.bridgelinesw.com/corpchoice-training/creative/flash/files/tour.htm";
            width = 780;
            height = 580;
        break;        
        case "omgeo":
            page = "http://www.bridgelinesw.com/omgeoalert/final/";
            width = 780;
            height = 560;
        break;        
        case "bony":
            page = "includes/bony/flash.htm";
            width = 600;
            height = 450;
        break;
        case "bony2":
            page = "http://www.bridgelinesw.com/bridgelineRichMedia/Bridgeline_portfolio/SmartSource/default.asp";
            width = 680;
            height = 400;
        break; 
        case "corpvideo":
            page = "http://www.bridgelinesw.com/corpvideo/ ";
            width = 775;
            height = 650;
        break;        
        default:
            page = "popPage.aspx?content=" + contentID;
            width = 550;
            height = 650;
            winName = "popWindow";
            sb = "yes";
        break;
    }
    window.open(page,winName,'width='+ width + ', height= ' + height + ', scrollbars=' + sb);
}

//Preload Images    
if (document.images){
    preload_image_object = new Image();
    // set image url
    image_url = new Array();
    image_url[0] = "~/images/menuBG.gif";
    image_url[1] = "~/images/menuBG_over.gif";
    image_url[2] = "~/images/mmBtn_separator_rightCurve.gif";
    image_url[3] = "~/images/mmBtn_separator_rightCurve.gif";
    image_url[4] = "~/images/mmBtn_resource Center_over.gif";
    image_url[5] = "~/images/mmBtn_customers_over.gif";
    image_url[6] = "~/images/mmBtn_company_over.gif";
    image_url[7] = "~/images/mmBtn_services_over.gif";
    image_url[8] = "~/images/mmBtn_products_over.gif";
    image_url[9] = "~/images/mmBtn_services.gif";
    image_url[10] = "~/images/mmBtn_resource Center.gif";
    image_url[11] = "~/images/mmBtn_products.gif";
    image_url[12] = "~/images/mmBtn_customers.gif";
    image_url[13] = "~/images/mmBtn_company.gif";
      
    var i = 0;
    for(i=0; i<=14; i++) 
    preload_image_object.src = image_url[i];
}

//Show hide Div
function showHideDiv(divID){
    var divElement = new Array()
    divElement[0] = "engage"
    divElement[1] = "discover"
    divElement[2] = "design"
    divElement[3] = "develop"
    divElement[4] = "deploy"
    divElement[5] = "review"
    for (i=0; i < divElement.length; i++)
    {
        if(divElement[i] == divID){
            document.getElementById(divElement[i]).className = "show";
        }else{
            document.getElementById(divElement[i]).className = "hide";
        }
    }
}

function whatWP()
{   
    var wpID = unescape(window.document.location);
    if (wpID.indexOf("?") > -1)
    { 
        var qs = wpID.split("?");
        var wpStr = qs[1].split("wpTitle");
        document.write(wpStr[1].replace("=",""));
    }
}
