isNS4 = (document.layers) ? true : false;
isIE5 = (document.all && document.getElementById) ? true : false;
isNS6 = (!document.all && document.getElementById) ? true : false;

/* Function that swaps images. */

function di20(id, newSrc) {
    var theImage = FWFindImage(document, id, 0);
    if (theImage) {
        theImage.src = newSrc;
    }
}

/* Functions that track and set toggle group button states. */

function FWFindImage(doc, name, j) {
    var theImage = false;
    if (doc.images) {
        theImage = doc.images[name];
    }
    if (theImage) {
        return theImage;
    }
    if (doc.layers) {
        for (j = 0; j < doc.layers.length; j++) {
            theImage = FWFindImage(doc.layers[j].document, name, 0);
            if (theImage) {
                return (theImage);
            }
        }
    }
    return (false);
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function ValidateEmail(sEmail)
{
	var filter  = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
	if (!filter.test(sEmail)) {
		return false;
	}
	return true;
}

function popObj(source){
	newView = window.open(source,"pic","width=400,height=380,resizable=0,scrollbars=0,toolbar=0,menubar=0,location=0")
	newView.focus();
}

function popVt(source){
	newView = window.open(source,"pic","width=650,height=580,resizable=0,scrollbars=0,toolbar=0,menubar=0,location=0")
	newView.focus();
}

function popRa(source){
	newView = window.open(source,"pic","width=650,height=400,resizable=0,scrollbars=1,toolbar=0,menubar=0,location=0")
	newView.focus();
}