function addMarkers() { mySelect = document.getElementById('selection'); Scottsdale = [];Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.81313324,33.59562683),"
Anasazi Elementary School
12121 N 124th Street
Scottsdale, AZ 85259

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Anasazi Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.94786072,33.49964905),"
Arcadia Neighborhood Learning Center
4330 N. 62nd Street
Scottsdale, AZ 85251

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Arcadia Neighborhood Learning Center",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86637000,33.60963200),"
Aztec Elementary School
13636 North 100th Street
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Aztec Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89469910,33.56549835),"
Basis Scottsdale
9128 E. San Salvador
Scottsdale, AZ 85258

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Basis Scottsdale",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92539215,33.59313965),"
Casy Country Day School #1
7214 E. Jenan Dr.5416
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Casy Country Day School #1",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92564392,33.59354019),"
Casy Country Day School #1 (charter)
7214 E. Jenan Dr.
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Casy Country Day School #1 (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.88880157,33.60729980),"
Casy Country Day School #2
9350 E. Cactus Road
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Casy Country Day School #2",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.88113403,33.59753799),"
Casy Country Day School #2 (charter)
9350 E. Cactus
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Casy Country Day School #2 (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92563000,33.59354400),"
Casy South Valley Academy
7214 Jenan Dr.
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Casy South Valley Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93215942,33.57836151),"
Chaparral High School
6935 E. Gold Dust
Scottsdale, AZ 85253

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Chaparral High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.84092712,33.58812714),"
Cheyenne Traditional Elementary School
11130 E. Cholla St.
Scottsdale, AZ 85259

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Cheyenne Traditional Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92042542,33.46556473),"
Classics And Four Arts Academy
7475 E Mcdowell Rd
Scottsdale, AZ 85257

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Classics And Four Arts Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89991760,33.57117462),"
Cochise Elementary School
9451 North 84th Street
Scottsdale, AZ 85258

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Cochise Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93862915,33.58936310),"
Cocopah Middle School
6615 E. Cholla St.
Scottsdale, AZ 85254

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Cocopah Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.96456146,33.64673996),"
Copper Canyon Elementary School
17650 North 54th Street
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Copper Canyon Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86369324,33.66781616),"
Copper Ridge Elementary School
10101 E. Thompson Peak Parkway
Scottsdale, AZ 85255

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Copper Ridge Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86369324,33.66781616),"
Copper Ridge Middle School
10101 E. Thompson Peak Parkway
Scottsdale, AZ 85255

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Copper Ridge Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92173767,33.47574234),"
Coronado High School
2501 North 74th Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Coronado High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89771271,33.50919724),"
Desert Canyon Elementary School
10203 E Mcdowell Mountain Ranc
Scottsdale, AZ 85255

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Desert Canyon Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86080170,33.62781143),"
Desert Canyon Middle School
10203 E. Mcdowell Mtn. Ranch R
Scottsdale, AZ 85255

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Desert Canyon Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86512756,33.48756790),"
Desert Eagle Secondary School
10,005 E. Osborn Rd.
Scottsdale, AZ 85256

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Desert Eagle Secondary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86512756,33.48756790),"
Desert Eagle Secondary School (charter)
10005 E. Osborne Rd.
Scottsdale, AZ 85256

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Desert Eagle Secondary School (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.81015778,33.58946228),"
Desert Mountain High School
12575 E. Via Linda
Scottsdale, AZ 85259

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Desert Mountain High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.95349121,33.60433578),"
Desert Shadows Elementary School
5902 E Sweetwater
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Desert Shadows Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.95458984,33.60438156),"
Desert Shadows Middle School
5858 E Sweetwater
Scottsdale, AZ 85254

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Desert Shadows Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.95214081,33.61987305),"
Desert Springs Elementary School
6010 East Acoma Road
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Desert Springs Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91780090,33.46709824),"
East Valley Academy
910 North 85th Place
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("East Valley Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91809845,33.46689987),"
East Valley Academy (charter)
910 N 85th Place
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("East Valley Academy (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91780090,33.46709824),"
Edupreneurship Student Center (esc) Chandler
1201 N., 85th Place - Rm 110
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Edupreneurship Student Center (esc) Chandler",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89720154,33.46054459),"
Edupreneurship Student Center (esc) Phoenix (chart
1201 N. 85th Place
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Edupreneurship Student Center (esc) Phoenix (chart",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89753723,33.46104813),"
Edupreneurship Student Center (esc) Scottsdale
1201 N., 85th Place
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Edupreneurship Student Center (esc) Scottsdale",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89720154,33.46054459),"
Edupreneurship Student Center (esc) Scottsdale (ch
1201 N. 85th Place
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Edupreneurship Student Center (esc) Scottsdale (ch",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92173767,33.47578049),"
Evit Scottsdale Voc Center
2507 N 74th Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Evit Scottsdale Voc Center",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92619324,33.77736282),"
Foothills Academy
7191 East Ashler Hills Drive
Scottsdale, AZ 85262

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Foothills Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91902924,33.67576599),"
Grayhawk Elementary School
7525 E. Grayhawk Dr.
Scottsdale, AZ 85255

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Grayhawk Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89878845,33.47296143),"
Hohokam Elementary School
8451 E. Oak Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Hohokam Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.96013641,33.62576294),"
Horizon High School
5601 E Greenway Road
Scottsdale, AZ 85254

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Horizon High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91780090,33.46709824),"
Horizons Back-to-basics Elementary School
7425 Culver
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Horizons Back-to-basics Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89469910,33.56549835),"
Kachina Country Day School
9318 N. 95th Way
Scottsdale, AZ 85258

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Kachina Country Day School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.87558746,33.52336502),"
Kachina Country Day School #2 (kachina School For
10460 N. 56th St
Scottsdale, AZ 85253

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Kachina Country Day School #2 (kachina School For",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.85509491,33.57817078),"
Laguna Elementary School
10475 E. Lakeview Dr.
Scottsdale, AZ 85258

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Laguna Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.95310211,33.61759949),"
Liberty Elementary School
5125 E. Marilyn Rd.
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Liberty Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.80075073,33.58253860),"
Mission Montessori Academy
12990 E. Shea Blvd.
Scottsdale, AZ 85259

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Mission Montessori Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89606476,33.51691437),"
Mohave Middle School
5520 N. 86th Street
Scottsdale, AZ 85250

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Mohave Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91842900,33.46773000),"
Montage Academy
7425 E. Culver
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Montage Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93586731,33.48076248),"
Montessori Academy
2928 N 67th Place
Scottsdale, AZ 85251

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Montessori Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.94525146,33.64041138),"
Montessori Day Public Schools Chartered - Scottsda
6239 E. Bell Road
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Montessori Day Public Schools Chartered - Scottsda",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.80496216,33.58720016),"
Mountainside Middle School
11256 N. 128th St.
Scottsdale, AZ 85259

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Mountainside Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.90013123,33.50308228),"
Navajo Elementary School
4525 N Granite Reef
Scottsdale, AZ 85251

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Navajo Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92038727,33.46564484),"
New School For Arts (charter)
7475 E. Mcdowell Road
Scottsdale, AZ 85257

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("New School For Arts (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.94950104,33.63542938),"
North Ranch Elementary School
16406 N. 61st Place
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("North Ranch Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.95310211,33.61759949),"
Patriot Academy Soaring Eagles Campus
5334 East Thunderbird Rd.
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Patriot Academy Soaring Eagles Campus",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92144012,33.46316147),"
Peoria Horizons Charter School
7425 E. Culver
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Peoria Horizons Charter School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.90145874,33.48773575),"
Pima Elementary School
8330 E. Osborn Road
Scottsdale, AZ 85251

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Pima Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91291046,33.69335556),"
Pinnacle Peak Elementary School
7690 E. Williams Dr.
Scottsdale, AZ 85255

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Pinnacle Peak Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.90456390,33.52960205),"
Pueblo Elementary School
6320 N. 82nd Street
Scottsdale, AZ 85250

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Pueblo Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92040253,33.49459839),"
Reinvent Ed Inc High School
P.o. Box 5987
Scottsdale, AZ 85261

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Reinvent Ed Inc High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.90456390,33.52728653),"
Saguaro High School
6250 N. 82nd Street
Scottsdale, AZ 85250

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Saguaro High School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.86573029,33.46593857),"
Salt River Day School
10000 East Mcdowell Road
Scottsdale, AZ 85256

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Salt River Day School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93598175,33.61513519),"
Sandpiper Elementary School
6724 E Hearn Road
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Sandpiper Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92144012,33.46316147),"
Scottsdale Horizons Charter School
7425 East Culver Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Scottsdale Horizons Charter School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.94346619,33.59320068),"
Sequoya Elementary School
11808 N. 64th St.
Scottsdale, AZ 85254

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Sequoya Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.89753723,33.46104813),"
Sierra Vista Academy
7501 E. Oak Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Sierra Vista Academy",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.92006683,33.60371017),"
Sonoran Sky Elementary School
12990 North 75th Street
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Sonoran Sky Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.96540700,33.61215800),"
Stars Prep Academy - Scottsdale, Inc.
5334 E. Thunderbird Rd.
Scottsdale, AZ 85254

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Stars Prep Academy - Scottsdale, Inc.",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.97300720,33.61893845),"
Sunrise Middle School
4960 East Acoma Drive
Scottsdale, AZ 85254

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Sunrise Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93618774,33.45846176),"
Supai Middle School
6720 East Continental
Scottsdale, AZ 85257

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Supai Middle School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93459320,33.47286224),"
Tonalea Elementary School
6801 E. Oak Street
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Tonalea Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.93527222,33.51734543),"
Villa Montessori - Scottsdale Campus (charter)
2928 N. 67th Place
Scottsdale, AZ 85253

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Villa Montessori - Scottsdale Campus (charter)",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.91763306,33.45574188),"
Yavapai Elementary School
701 North Miller Road
Scottsdale, AZ 85257

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Yavapai Elementary School",'Scottsdale=' + Scottsdale.length); Scottsdale[Scottsdale.length] = createMarker(new GPoint(-111.88328552,33.61506653),"
Zuni Elementary School
9181 E. Redfield Rd.
Scottsdale, AZ 85260

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Zuni Elementary School",'Scottsdale=' + Scottsdale.length); maxLng = -111.80075073; maxLat = 33.77736282; minLng = -111.97300720; minLat = 33.45574188; reCenterMap(); } // 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,10); /* 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(Scottsdale); 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(Scottsdale);map.removeOverlays(Scottsdale); map.addOverlays(Scottsdale); centerByArray(Scottsdale, false, false); cntMarker += Scottsdale.length; centerByArray(Scottsdale,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'); } }