<!-- Begin hiding from old browsers
/*Break frames*/
     if (top.frames.length!=0)
     top.location=self.document.location;
/*Pop-up page, variable width, height; closes when focus is lost*/
var openwin = null;
function KeepTop ()
{
   if (openwin != null && openwin.open) openwin.close();
}
function WinSize(loc,winwidth,winheight)
{
wintype =
'width='+winwidth+',height='+winheight+',toolbar=no,menubar=no,location=no,status=no,copy history=no,scrollbars=yes,resizable=yes,top=0,left=0,screenX=0,screenY=0';
openwin = window.open(loc,'CtrlWindow',wintype);
}
window.onfocus=KeepTop;
/*Make Sure a Phone Number is Supplied*/
function checkFields() {
home = document.bidform.home_phone.value;
work = document.bidform.work_phone.value;
cell = document.bidform.cell_phone.value;
if ((home == "") && (work == "") && (cell == "")){
alert("Please provide a phone number.");
return false;
}}

/*Format Bids to Dollars*/
function formatCurrency(num) {
num = num.toString().replace(/\$|\,/g,'');
if(isNaN(num))
num = "0";
sign = (num == (num = Math.abs(num)));
num = Math.floor(num*100+0.50000000001);
cents = num%100;
num = Math.floor(num/100).toString();
if(cents<10)
cents = "0" + cents;
for (var i = 0; i < Math.floor((num.length-(1+i))/3); i++)
num = num.substring(0,num.length-(4*i+3))+','+
num.substring(num.length-(4*i+3));
return (((sign)?'':'-') + '$' + num + '.' + cents);
}
/*Disable Submit While Sending*/
function disableForm(theform) {
if (document.all || document.getElementById) {
for (i = 0; i < theform.length; i++) {
var tempobj = theform.elements[i];
if (tempobj.type.toLowerCase() == "submit" || tempobj.type.toLowerCase() == "reset")
tempobj.disabled = true;
}}}
// End hiding from old browsers-->