function addMarkers(){ mySelect = document.getElementById('selection'); Metairie = [];Metairie[Metairie.length] = createMarker(new GPoint(-90.22330100,30.00538400),"
Archbishop Chapelle High School
8800 Veterans Memorial Blvd
Metairie, LA 70003
All-girls school, 8-12
[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Archbishop Chapelle High School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.16750000,29.98440000),"
Archbishop Rummel High School
Po Box 663 1901 Severn Avenue
Metairie, LA 70004
All-boys school, 8-12
[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Archbishop Rummel High School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.21673200,30.00918700),"
Atonement Lutheran School
6500 Riverside Drive
Metairie, LA 70003
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Atonement Lutheran School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.18969800,30.00026600),"
Crescent City Christian School
4828 Utica Street
Metairie, LA 70006
Co-ed school, PK-12
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Crescent City Christian School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.20250400,30.01509400),"
Ecole Classique
5236 Glendale Street
Metairie, LA 70006
Co-ed school, 5-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Ecole Classique",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.21528400,30.00221600),"
Heritage Academy
2900 Wytchwood Drive
Metairie, LA 70003
Co-ed school, 9-12
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Heritage Academy",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.19806000,29.98179700),"
Kehoe-france School
720 Elise Avenue
Metairie, LA 70003
Co-ed school, NS-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Kehoe-france School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.17171600,30.00866300),"
Lutheran High School
3864 17th Street
Metairie, LA 70002
Co-ed school, 9-12
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Lutheran High School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.20419600,30.00629300),"
Memorial Baptist Christian
5701 Veterans Memorial Blvd
Metairie, LA 70003
Co-ed school, 1-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Memorial Baptist Christian",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.13251900,29.98213700),"
Metairie Park Country Day School
300 Park Road
Metairie, LA 70005
Co-ed school, K-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Metairie Park Country Day School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.16612000,30.01523400),"
New Orleans Jewish Day School
W Esplanade Avenue N
Metairie, LA 70002
Co-ed school, K-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("New Orleans Jewish Day School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.22688100,29.98782000),"
Our Lady Of Divine Providence School
917 N Atlanta Street
Metairie, LA 70003
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Our Lady Of Divine Providence School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.20414300,29.98942800),"
Parkway Presbyterian Pre-school
6200 Camphor Street
Metairie, LA 70003
Co-ed school, NS-PK
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Parkway Presbyterian Pre-school",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.17316600,29.97615900),"
Ridgewood Preparatory School
201 Pasadena Avenue
Metairie, LA 70001
Co-ed school, PK-12
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Ridgewood Preparatory School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.14690300,30.00350500),"
St. Angela Merici School
835 Melody Drive
Metairie, LA 70002
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Angela Merici School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.19418700,30.00887700),"
St. Ann Elementary School
4921 Meadowdale Street
Metairie, LA 70006
Co-ed school, PK-7
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Ann Elementary School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.16425900,29.98897600),"
St. Benilde School
1801 Division Street
Metairie, LA 70001
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Benilde School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.14227000,29.98788000),"
St. Catherine Of Siena
400 Codifer Blvd
Metairie, LA 70005
Co-ed school, PK-7
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Catherine Of Siena",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.18726500,29.98347800),"
St. Edward The Confessor School
4901 W Metairie Avenue
Metairie, LA 70001
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Edward The Confessor School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.12354300,30.01624900),"
St. Louis King Of France School
1600 Lake Avenue
Metairie, LA 70005
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Louis King Of France School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.21716800,30.01207400),"
St. Philip Neri School
6600 Kawanee Avenue
Metairie, LA 70003
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St. Philip Neri School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.16976500,29.97677400),"
St Christopher Elementary School
3900 Derbigny Street
Metairie, LA 70001
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St Christopher Elementary School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.17460400,30.01523800),"
St Clement Of Rome School
3978 W Esplanade Avenue S
Metairie, LA 70002
Co-ed school, 5-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St Clement Of Rome School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.12938200,29.98411900),"
St Francis Xavier School
215 Betz Place
Metairie, LA 70005
Co-ed school, 5-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St Francis Xavier School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.18946300,29.97638600),"
St Martin's Episcopal School
5309 Airline Drive
Metairie, LA 70003
Co-ed school, PK-12
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St Martin's Episcopal School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.20604800,29.98480400),"
St Mary Magdalen School
6421 W Metairie Avenue
Metairie, LA 70003
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("St Mary Magdalen School",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.20360600,30.01706300),"
Torah Academy
5210 W Esplanade Avenue
Metairie, LA 70006
Co-ed school, 5-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Torah Academy",'Metairie=' + Metairie.length); Metairie[Metairie.length] = createMarker(new GPoint(-90.19345000,29.97644500),"
Victory Christian Academy
5708 Airline Drive
Metairie, LA 70003
Co-ed school, PK-8
[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Victory Christian Academy",'Metairie=' + Metairie.length); } // End addStateMarkers JavaScript Function // Takes an array of markers and centers/zooms map based on marker range function centerByArray(myArray, recenter, newMaxMin) { if (newMaxMin == true) reMaxMin(myArray); for (var i = 0; i < myArray.length; i++) { var markLng = myArray[i].getPoint().x; var markLat = myArray[i].getPoint().y; if (markLat > maxLat) maxLat = markLat; if (markLng > maxLng) maxLng = markLng; if (markLat < minLat) minLat = markLat; if (markLng < minLng) minLng = markLng; } if (recenter) reCenterMap(); } // Reinit max/mins function reMaxMin(myArray) { maxLng = myArray[0].getPoint().x; maxLat = myArray[0].getPoint().y; minLng = myArray[0].getPoint().x; minLat = myArray[0].getPoint().y; } // Recenter map based on global max/mins function reCenterMap() { var bounds = new GLatLngBounds(); bounds.extend(new GLatLng(minLat, minLng)); bounds.extend(new GLatLng(maxLat, maxLng)); var center_lat = (bounds.getNorthEast().lat() + bounds.getSouthWest().lat()) / 2.0; var center_lng = (bounds.getNorthEast().lng() + bounds.getSouthWest().lng()) / 2.0; var center = new GLatLng(center_lat, center_lng); var zoom = map.getBoundsZoomLevel(bounds); map.setCenter(center,zoom); //map.setCenter(center,11); /* var center = new GPoint( (maxLng + minLng)/2, (maxLat+minLat)/2 ); var delta = new GSize(maxLng - minLng, maxLat - minLat); var minZoom = map.spec.getLowestZoomLevel(center, delta, map.viewSize); if (minZoom < 4) minZoom = 4; // Lowest possible zoom is 4 map.centerAndZoom(center, minZoom); */ } // Fires when drop down list of schools changes function selectChange(selection) { var myVal = selection.options[selection.selectedIndex].value; map.closeInfoWindow(); // Add entire array based on variable type if (myVal.indexOf('all') != -1 && myVal != 'all') { var temp = myVal.split('='); var showArray = temp[1]; // If Array is > X amount of markers, then open in a new page if (eval(showArray).length > 20) // New window depends on whether or not we're on the search page if (location.href.indexOf('nearby_schools.php') == -1) window.open(location.href + '/map/' + showArray); else window.open('/search//////' + showArray); map.removeOverlays(Metairie); map.addOverlays(eval(showArray)); centerByArray(eval(showArray), true, true); // Center and zoom on set of markers } // Add individual markers if (myVal.indexOf('all') == -1 && myVal != 'all' && myVal.length) { var temp = myVal.split('='); var myArray = temp[0]; var myIndex = parseInt(temp[1]) - 1; document.getElementById('map').width = "750"; map.removeOverlay(eval(myArray)[myIndex]); map.addOverlay(eval(myArray)[myIndex]); GEvent.trigger(eval(myArray)[myIndex],'click'); } // Show all markers if (myVal == 'all') { cntMarker = 0; reMaxMin(Metairie);map.removeOverlays(Metairie); map.addOverlays(Metairie); centerByArray(Metairie, false, false); cntMarker += Metairie.length; centerByArray(Metairie,true, false); if (cntMarker > 20) // New window depends on whether or not we're on the search page if (location.href.indexOf('schools-by-distance') == -1) window.open(location.href + '/map/all'); else window.open('/search////all'); //window.open('/map.php?type=1&schools=&school_level=&radius=&zipcode=&school_type_search=&school_type_code='); } } function createMarker(point, label, icon) { var marker = new GMarker(point, icon); var html = label; GEvent.addListener(marker, "click", function() { marker.openInfoWindowHtml(html); }); return marker; }