﻿function NavMouseOver(element) {
   element.style.backgroundColor = 'blue'; 
   element.style.color = 'white';
}

function NavMouseOut(element) {
    element.style.backgroundColor = '#BBC8E1'; 
    element.style.color = 'Yellow';
}

function PopWin(url) {
	win = open(url, 'powin2', 'width=790,height=600,left=20,top=20,status=yes, menubar=no, scrollbars=yes, resizable=yes');
	win.opener = self;
	win.focus();
}



function ShowBrowserName()
{ 
    alert("It appears you are using the '" + navigator.appName + "' browser.");
}


function PopBBB(url) {
    win = open('http://northeastflorida.bbb.org/codbrep.html?wlcl=y&id=202520793', 'popBBBwin2', 'width=790,height=600,left=20,top=20,status=yes, menubar=no, scrollbars=yes, resizable=yes');
    win.opener = self;
    win.focus();
}
 

/* Mortg Calc */

function floor(number)
{
    //return Math.floor(number*Math.pow(10,2))/Math.pow(10,2);
}

function dosum()
{
    /*
     var mi = document.temps.IR.value / 1200;
     var base = 1;
     var mbase = 1 + mi;
     for (i=0; i<document.temps.YR.value * 12; i++)
     {
     base = base * mbase
     }
     document.temps.PI.value = floor(document.temps.LA.value * mi / ( 1 - (1/base)))
     document.temps.MT.value = floor(document.temps.AT.value / 12)
     document.temps.MI.value = floor(document.temps.AI.value / 12)
     var dasum = document.temps.LA.value * mi / ( 1 - (1/base)) +
     document.temps.AT.value / 12 + 
     document.temps.AI.value / 12;
     document.temps.MP.value = floor(dasum);
     */
}

/* PROGRESS BAR INTEROP ------------------------------------------------- */
// Called by Referral Control's modal windows.
function ShowProgressImage(txtBoxID, requiredLength) {
    var textBx = document.getElementById(txtBoxID);
    if (textBx != null) {
        if (textBx.value.length >= requiredLength) {
            textBx.style.backgroundImage = "url('../Images/indicator_white.gif')";
            textBx.style.backgroundRepeat = 'no-repeat';
            textBx.style.backgroundPosition = 'right';
        }
        else {
            HideProgressImage(txtBoxID);
        }
    }
}

function HideProgressImage(txtBoxID) {
    var textBx = document.getElementById(txtBoxID);
    if (textBx != null)
        textBx.style.backgroundImage = "";
}
/* END PROGRESS BAR INTEROP ------------------------------------------------- */



