 var Icon1 = new GIcon();
        Icon1.image = "http://www.4feldco.com/images/feldco_logo.png";
        Icon1.iconSize = new GSize(80,50);
        Icon1.iconAnchor = new GPoint(80,50);
        Icon1.infoWindowAnchor = new GPoint(50,1);
        var gmarkers = [];
        var htmls = [];
        var i = 0;
    function load() {
      if (GBrowserIsCompatible()) {
           /* 
          var map, point, marker, map1, point1, marker1, map2, point2, marker2, map3, point3, marker3, map4, point4, marker4;
          var map5, point5, marker5, map6, point6, marker6, map7, point7, marker7, point8, marker8,map8;
            point = new GLatLng(42.023153,-87.915841);   
            map = createMap(document.getElementById("feldco1"),point);
            map.addOverlay(createMarker(point,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='125 E. Oakton Des Plaines, IL 60018' /><input type='hidden' name='hl' value='en' /><table width='179' border='0' cellspacing='5' cellpadding='5'><tr><td><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='200px' height='50px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions' class='mButton' /></td></tr></table></form>"));
            point1 = new GLatLng(41.713045, -87.681849);
            map1 = createMap(document.getElementById("feldco2"),point1);
            map1.addOverlay(createMarker(point1,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='9932 S Western Avenue, Evergreen Park, IL 60643' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions' class='mButton'/></td></tr></table></form>"));
            point2 = new GLatLng(41.834170, -88.022162);
            map2 = createMap(document.getElementById("feldco3"),point2);
            map2.addOverlay(createMarker(point2,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='1406 Butterfield Road Downers Grove, IL 60515' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));   
            point3 = new GLatLng(42.26590, -88.98000);
            map3 = createMap(document.getElementById("feldco4"),point3);
            map3.addOverlay(createMarker(point3,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='747 South Perryville Road, Rockford,  IL  61108' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));   
            point4 = new GLatLng(43.019835, -88.042374);
            map4 = createMap(document.getElementById("feldco5"),point4);
            map4.addOverlay(createMarker(point4,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='1708 S. 108th Street West Allis, WI 53214' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));
            point5 = new GLatLng(39.913719, -86.0390317440033);
            map5 = createMap(document.getElementById("feldco6"),point5);
            map5.addOverlay(createMarker(point5,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='8818 Corporation Drive, Indianapolis, IN' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));
            point6 = new GLatLng(43.0539824, -89.3086351);
            map6 = createMap(document.getElementById("feldco7"),point6);
            map6.addOverlay(createMarker(point6,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='3037 S Stoughton Road, Madison, WI, 53716' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));
            point7 = new GLatLng(40.494241, -89.0219816);
            map7 = createMap(document.getElementById("feldco8"),point7);
            map7.addOverlay(createMarker(point7,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='1103 Martin Luther King Jr. Drive Building H Bloomington, IL 61704 ' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));  			
            
            point8 = new GLatLng(44.23579, -88.42391);
            map8 = createMap(document.getElementById("feldco9"),point8);
            map8.addOverlay(createMarker(point8,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='1125 Tuckaway Lane #C Menasha, WI 54952' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));
         
         
         */
          smartCreateMap("feldco1", new GLatLng(42.023153, -87.915841), "125 E. Oakton Des Plaines, IL 60018");
          smartCreateMap("feldco2", new GLatLng(41.713045, -87.681849), "9932 S Western Avenue, Evergreen Park, IL 60643");
          smartCreateMap("feldco3", new GLatLng(41.834170, -88.022162), "1406 Butterfield Road Downers Grove, IL 60515");
          smartCreateMap("feldco4", new GLatLng(42.26590, -88.98000), "747 South Perryville Road, Rockford,  IL  61108");
          smartCreateMap("feldco5", new GLatLng(43.019835, -88.042374), "1708 S. 108th Street West Allis, WI 53214");
          smartCreateMap("feldco6", new GLatLng(39.913719, -86.0390317440033), "8818 Corporation Drive, Indianapolis, IN");
          smartCreateMap("feldco7", new GLatLng(43.0539824, -89.3086351), "3037 S Stoughton Road, Madison, WI, 53716");
          smartCreateMap("feldco8", new GLatLng(40.494241, -89.0219816), "1103 Martin Luther King Jr. Drive Building H Bloomington, IL 61704");
          smartCreateMap("feldco9", new GLatLng(44.23579, -88.42391), "1125 Tuckaway Lane #C Menasha, WI 54952");
      
      }
    }
    function smartCreateMap(plhID, point, addr) {
        var mapPLH = document.getElementById(plhID);
        if(null != mapPLH){
            var map = createMap(mapPLH, point);
            if(null != map) {
                map.addOverlay(createMarker(point,"<form action='http://maps.google.com/maps' method='get' target='_blank'><input type='hidden' name='daddr' value='" + addr + "' /><input type='hidden' name='hl' value='en' /><table width='150' border='0' cellspacing='5' cellpadding='5'><tr><td class='mText'><label for='saddr'>Start address:</label></td></tr><tr><td><textarea name='saddr' cols='20' id='saddr' width='150px'></textarea></td></tr><tr><td><input name='submit' type='submit' value='Get Directions'  class='mButton'/></td></tr></table></form>"));
            }
            map = null;
        }
        mapPLH = null;
    }
    function createMap(mapID, point) {
     
        var map = new GMap2(mapID);
        map.setCenter(point, 15);
        map.addControl(new GSmallMapControl());
        map.addControl(new GMapTypeControl()); 
        return map;
      }
    function createMarker(point,html) {
        var marker = new GMarker(point,Icon1);
        GEvent.addListener(marker, "click", function() {
          marker.openInfoWindowHtml(html);
        });
        gmarkers[i] = marker;
        htmls[i] = html;
        i++;
        return marker;
      }  
      function GetDirections(i) {
        gmarkers[i].openInfoWindowHtml(htmls[i]);
      }
