function showForm(nameForm) { 
     var startUrl = nameForm;
     window.open(startUrl,'EntryForm','toolbar=no,location=yes,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=700,height=450,left=120,top=120'); 
     return false; 
} 
function submitForm(SearchDisciplene, obj){
  var SectionInSylulabus = obj.value; 
  if ( SectionInSylulabus !='' ){         
       document.MyForm.SearchDisciplene.value = SearchDisciplene;
       document.MyForm.SectionInSylulabus.value = SectionInSylulabus;
       document.MyForm.submit();
       return true;
  }
  return false;
}

function convertSpaces(str) {
      var out = "";
      for (i = 0; i < str.length; i++) {
          if ( str.charAt(i) != " ") {
                       out += str.charAt(i);
          }else{    out += "+";       }
      }
      return out;
}

function showMap(numHall) { 
      var startUrl = "http://webmap.city.london.on.ca/mapclient/mapbroker.asp?name=WebMap&M=9&U=1&L3=29-";
      var endUrl = "&Z2=5&O=SubjectSites";
      var addressHall =  document.myForm["AddressHall"+numHall].value;
      var convStr =  convertSpaces(addressHall);
      var mapUrl =  startUrl + convStr + endUrl;
      window.open(mapUrl,'mapWindow','toolbar=no,location=no,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=700,height=450,left=120,top=120'); 
      return false; 
} 

function showPressRelease(startUrl) { 
     window.open(startUrl,'mapWindow','toolbar=no,location=no,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=790,height=450,left=50,top=50'); 
     return false; 
} 

function showWebMap(numHall) { 
      window.open(numHall,'mapWindow','toolbar=no,location=no,directories=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=700,height=450,left=120,top=120'); 
      return false; 
} 
