var map = null;
var geocoder = null;
var mrk = null;
var mpnt = null;
var mapdiv = null;
var myOptions = null;

function mapLoad( itm, addr ) {
    geocoder = new google.maps.Geocoder();
    var address = addr;

    var myOptions = {
      zoom: 14,
      mapTypeId: google.maps.MapTypeId.ROADMAP
    }

    if (geocoder) {
      geocoder.geocode( { 'address': address}, function(results, status) {
        if (status == google.maps.GeocoderStatus.OK) {

		  map = new google.maps.Map(document.getElementById("map"), myOptions);
          map.setCenter(results[0].geometry.location);

          var marker = new google.maps.Marker({
              map: map,
              position: results[0].geometry.location
          });
        } else {
          //alert("Geocode was not successful for the following reason: " + status);
        }
      });
    }
}


function mapLoad2( itm, pntx, pnty ) {
    var latlng = new google.maps.LatLng(pnty, pntx);

    var myOptions = {
          zoom: 14,
          center: latlng,
          mapTypeId: google.maps.MapTypeId.ROADMAP
    }

    map = new google.maps.Map(document.getElementById(itm), myOptions);  

	var marker = new google.maps.Marker( {
	    map: map,
	    position: new google.maps.LatLng(pnty, pntx)
	});
}
