if (top != self) {
	top.location=location
}

if (document.layers) {
 window.resize = reloadIt;
 }
 
function reloadIt() {
     document.location = document.location;
}
bIE = false;
av = navigator.appVersion;
iMSIE=parseInt(av.indexOf("MSIE"));
if (iMSIE >= 1)
 bIE = true;
function activateFrame(obj, htm_str) {
   document.frameForm.href_value_outside.value=obj.href;
   document.frameForm.href_value_inside.value=window.location;
   var emptyFURL = "http://";
   emptyFURL += window.location.host;
   emptyFURL += "/frames/redirects/";
   emptyFURL += htm_str;
   document.frameForm.href_value_hidden.value=emptyFURL;
   var actionURL = "http://";
   actionURL += window.location.hostname;
   actionURL += "/cgi-bin/publish/frame.cgi";
   document.frameForm.action = actionURL;
   document.frameForm.submit();
   if (bIE) {
     window.event.returnValue = false;
   }
   return false;   
}

function jump(which) {
    var menu = which;
    var url = menu.options[menu.selectedIndex].value;
    eval("window.location ='" + url + "'");
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function getEmail(eaddress,ccAddress) {
if (eaddress == "other@sfgov.org") 
  var dummy
else 

document.contactUs.submit_to.value = eaddress;
document.contactUs.form_id.value = ccAddress;

}

function getEmailOther() {
if (document.contactUs.form_id_select.options[document.contactUs.form_id_select.selectedIndex].value  == "blank") 
//document.contactUs.submit_to.value=""
alert("Please choose a department");
else{

var strSubmit;
var strFormId;
var valueArray;
valueArray = document.contactUs.form_id_select.options[document.contactUs.form_id_select.selectedIndex].value .split(",");
strFormId = valueArray[0];
strSubmit = valueArray[1];
document.contactUs.submit_to.value = strSubmit
document.contactUs.form_id.value = strFormId;
 }
}

function emailSubmit() {
//alert(document.contactUs.submit_to.value);
//alert(document.contactUs.form_id.value);
if (document.contactUs.form_id_select.options[document.contactUs.form_id_select.selectedIndex].value  == "blank") 

alert("Please choose a department");
else{
if (document.contactUs.submit_to.value=="") 

alert("please choose a department");
else {
document.contactUs.submit();

}}}

var newString = "";
var wordQuotes = "";

// for dropdown menus
function menujump(item) {
    var url = item.options[item.selectedIndex].value;
    if(url.length > 0) {
	   window.location = url;
	}
}

