<!--
var popWindowRef;
var bermudaURL = "http://www.lookbermuda.net/";


function popOpen(url,name,attributes,id) {
    if (typeof popWindowRef == 'undefined' || popWindowRef.closed) { popWindowRef = window.open(url,name,attributes); }
    if (window.focus) { popWindowRef.focus(); document.getElementById("iframe").src = bermudaURL + "localConnection.htm?mapid="+id; }
}


// doesn't use the local object, simply refreshes the popup window
function refreshOpen(url,name,attributes,id) {
    if (typeof popWindowRef == 'undefined' || popWindowRef.closed) { popWindowRef = window.open(url,name,attributes); }
    if (window.focus) { popWindowRef.focus(); popWindowRef.location.href = url; }
}

function openMap(mapid, client) {
    if (typeof mapid== 'undefined' || mapid == '' )
        mapid = "8000";


    var url = bermudaURL + "bermuda.aspx?id=" + mapid + "&client=" + client;
    //http://www.lookbermuda.net/point.aspx?id=
    if( typeof client == 'undefined' || client == '' )
        refreshOpen(url,'map','toolbar=no,resizable=yes,scrollbars=auto,left=0,top=0,screenX=0,screenY=0,width='+1020+',height='+725+'',mapid)
    else
        popOpen(url,'map','toolbar=no,resizable=yes,scrollbars=auto,left=0,top=0,screenX=0,screenY=0,width='+1020+',height='+725+'',mapid)
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
    window.open(theURL,winName,features);
}

function parseRFPsubmit(){
    var starcite = "http://www.starcite.com/rapidrfp/wizards/bermuda.asp";
    var upload   = "65.aspx";
    
    var val;
    
    if(document.getElementById("attach").checked == true){
        self.location.href = self.location.protocol + "65.aspx";
    }else{
        openPopup(starcite, 'starcite', 800, 700, 1, 1, 1, 1, 1);
    }
}

function openPopup(URL, windowName, width, height, resize, scrollbar, toolbar, menubar, status, left, top){
	if (scrollbar == null || scrollbar == 'undefined'){scrollbar=1;}
	if (left==null || left == 'undefined'){left = (screen.availWidth/2) - (width/2)}
	if (top==null || top == 'undefined'){top = (screen.availHeight/2) - (height/2)}
	var Win = window.open(URL, windowName,'width=' + width + ',height=' + height + ',resizable=' + resize + ',scrollbars=' + scrollbar + ',toolbar=' + toolbar + ',menubar=' + menubar + ',status=' + status + ',left=' + left + ',top=' + top);
	Win.focus();
}

function setBGColor(id,color){ 
	document.getElementById(id).style.backgroundColor = color; 
}

sfHover = function(){
  var sfEls = document.getElementById("menu").getElementsByTagName("li");
  for (var i=0; i<sfEls.length; i++) {
    sfEls[i].onmouseover=function() { this.className+=" sfhover"; }
    sfEls[i].onmouseout=function() { this.className = this.className.replace(new RegExp(" sfhover\\b"), ""); }
  }
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

function hideElements(id, elementType) { 
  if(document.getElementById(id)){
	var arrSelectLists = document.getElementById(id).getElementsByTagName(elementType);
	var obj;
	
	for(i = 0; i < arrSelectLists.length; i++){
	  obj = arrSelectLists[i]
	  
	  if(obj.style.visibility == 'hidden'){
	    obj.style.visibility = 'visible'; 
	  }else{
	    obj.style.visibility = 'hidden'; 
	  }
	}
  }
}

function isLetter(chr){
    if ((chr.charCodeAt(0) >= 65 && chr.charCodeAt(0) <= 90) || (chr.charCodeAt(0) >= 97 && chr.charCodeAt(0) <= 122)){
        return true;
    }else{
        return false;    
    }
}
function check_email(email) {
    if(email.length < 5){
        return(false);
    }else if(email.indexOf("@") != email.lastIndexOf("@")){
        return(false);
    }else if(email.indexOf("@") < 1){
        return(false);
    }else if(email.indexOf("@") > email.length - 4){
        return(false);
    }else if(email.indexOf(".") < 1){
        return(false);
    }else if(email.lastIndexOf(".") == email.length - 1){
        return(false);
    }else if(email.charAt(email.indexOf("@") + 1) == "."){
        return(false);
    }else if(email.charAt(email.indexOf("@") - 1) == "."){
        return(false);
    }else if(email.lastIndexOf(".") < email.indexOf("@")){
        return(false);
    }else{
        return(true);
    }
}

    function PageQuery(q) {
        if(q.length > 1) this.q = q.substring(1, q.length);
        else this.q = null;
        this.keyValuePairs = new Array();
        if(q){
            for(var i=0; i < this.q.split("&").length; i++){
                this.keyValuePairs[i] = this.q.split("&")[i];
            }
        }
        this.getKeyValuePairs = function() { return this.keyValuePairs; }
        this.getValue = function(s) {
            for(var j=0; j < this.keyValuePairs.length; j++) {
                if(this.keyValuePairs[j].split("=")[0] == s)
                return this.keyValuePairs[j].split("=")[1];
            }
            return false;
        }
        this.getParameters = function() {
            var a = new Array(this.getLength());
            for(var j=0; j < this.keyValuePairs.length; j++) {
                a[j] = this.keyValuePairs[j].split("=")[0];
            }
            return a;
        }
        this.getLength = function() { return this.keyValuePairs.length; } 
    }
    function queryString(key){
        var page = new PageQuery(window.location.search); 
        return unescape(page.getValue(key)); 
    }
	
function docWriter(lyrID,strObj){
	document.getElementById(lyrID).innerHTML = strObj;
}

// -->