function addMarkers() { mySelect = document.getElementById('selection'); Winsted = [];Thomaston = [];New_Hartford = [];Barkhamsted = [];Bethlehem = [];Roxbury = [];Norfolk = [];Bridgewater = [];Litchfield = [];Colebrook = [];West_Cornwall = [];Washington = [];Torrington = [];Watertown = [];Goshen = [];Terryville = [];Harwinton = [];New_Milford = [];Falls_Village = [];Woodbury = [];Morris = [];Oakville = [];Kent = [];North_Canaan = [];Winchester = [];Plymouth = [];Lakeville = [];Sharon = [];Warren = [];Washington_Dep = [];mySelect.options[mySelect.options.length] = new Option("Barkhamsted schools",'all=Barkhamsted'); mySelect.options[mySelect.options.length] = new Option("Bethlehem schools",'all=Bethlehem'); mySelect.options[mySelect.options.length] = new Option("Bridgewater schools",'all=Bridgewater'); mySelect.options[mySelect.options.length] = new Option("Colebrook schools",'all=Colebrook'); mySelect.options[mySelect.options.length] = new Option("Falls Village schools",'all=Falls_Village'); mySelect.options[mySelect.options.length] = new Option("Goshen schools",'all=Goshen'); mySelect.options[mySelect.options.length] = new Option("Harwinton schools",'all=Harwinton'); mySelect.options[mySelect.options.length] = new Option("Kent schools",'all=Kent'); mySelect.options[mySelect.options.length] = new Option("Lakeville schools",'all=Lakeville'); mySelect.options[mySelect.options.length] = new Option("Litchfield schools",'all=Litchfield'); mySelect.options[mySelect.options.length] = new Option("Morris schools",'all=Morris'); mySelect.options[mySelect.options.length] = new Option("New Hartford schools",'all=New_Hartford'); mySelect.options[mySelect.options.length] = new Option("New Milford schools",'all=New_Milford'); mySelect.options[mySelect.options.length] = new Option("Norfolk schools",'all=Norfolk'); mySelect.options[mySelect.options.length] = new Option("North Canaan schools",'all=North_Canaan'); mySelect.options[mySelect.options.length] = new Option("Oakville schools",'all=Oakville'); mySelect.options[mySelect.options.length] = new Option("Plymouth schools",'all=Plymouth'); mySelect.options[mySelect.options.length] = new Option("Roxbury schools",'all=Roxbury'); mySelect.options[mySelect.options.length] = new Option("Sharon schools",'all=Sharon'); mySelect.options[mySelect.options.length] = new Option("Terryville schools",'all=Terryville'); mySelect.options[mySelect.options.length] = new Option("Thomaston schools",'all=Thomaston'); mySelect.options[mySelect.options.length] = new Option("Torrington schools",'all=Torrington'); mySelect.options[mySelect.options.length] = new Option("Warren schools",'all=Warren'); mySelect.options[mySelect.options.length] = new Option("Washington schools",'all=Washington'); mySelect.options[mySelect.options.length] = new Option("Washington Dep schools",'all=Washington_Dep'); mySelect.options[mySelect.options.length] = new Option("Watertown schools",'all=Watertown'); mySelect.options[mySelect.options.length] = new Option("West Cornwall schools",'all=West_Cornwall'); mySelect.options[mySelect.options.length] = new Option("Winchester schools",'all=Winchester'); mySelect.options[mySelect.options.length] = new Option("Winsted schools",'all=Winsted'); mySelect.options[mySelect.options.length] = new Option("Woodbury schools",'all=Woodbury'); mySelect.options[mySelect.options.length] = new Option("---------------------------",''); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Able
201 Pratt Street
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Able",'Winsted=' + Winsted.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Aim
100 Battistoni Drive
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Aim",'Winsted=' + Winsted.length); Thomaston[Thomaston.length] = createMarker(new GPoint(-73.07440186,41.67385864),"
Alternative Community Education High School
Thomas Ave.
Thomaston, CT 06787

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Alternative Community Education High School",'Thomaston=' + Thomaston.length); New_Hartford[New_Hartford.length] = createMarker(new GPoint(-73.01654053,41.82966995),"
Ann Antolini School
30 Antolini Rd.
New Hartford, CT 06057

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Ann Antolini School",'New_Hartford=' + New_Hartford.length); New_Hartford[New_Hartford.length] = createMarker(new GPoint(-73.03349304,41.83172989),"
Bakerville Consolidated School
51 Cedar Lane
New Hartford, CT 06057

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Bakerville Consolidated School",'New_Hartford=' + New_Hartford.length); Barkhamsted[Barkhamsted.length] = createMarker(new GPoint(-72.99382782,41.91015625),"
Barkhamsted Elementary School
65 Ripley Hill Rd.
Barkhamsted, CT 06063

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Barkhamsted Elementary School",'Barkhamsted=' + Barkhamsted.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.07567596,41.90930557),"
Batcheller Elementary School
201 Pratt St.
Winsted, CT 06098

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Batcheller Elementary School",'Winsted=' + Winsted.length); Bethlehem[Bethlehem.length] = createMarker(new GPoint(-73.19949341,41.63973999),"
Bethlehem Elementary School
92 East St.
Bethlehem, CT 06751

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Bethlehem Elementary School",'Bethlehem=' + Bethlehem.length); Thomaston[Thomaston.length] = createMarker(new GPoint(-73.09296417,41.65785599),"
Black Rock School
57 Branch Rd.
Thomaston, CT 06787

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Black Rock School",'Thomaston=' + Thomaston.length); Roxbury[Roxbury.length] = createMarker(new GPoint(-73.30838013,41.55460358),"
Booth Free School
14 South St.
Roxbury, CT 06783

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Booth Free School",'Roxbury=' + Roxbury.length); Norfolk[Norfolk.length] = createMarker(new GPoint(-73.20384216,41.99477005),"
Botelle Elementary School
128 Greenwoods Rd. Eas
Norfolk, CT 06058

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Botelle Elementary School",'Norfolk=' + Norfolk.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Bridges 2
15 Hinsdale Avenue
Winsted, CT 06098

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Bridges 2",'Winsted=' + Winsted.length); Barkhamsted[Barkhamsted.length] = createMarker(new GPoint(-72.99138600,41.91153200),"
Bridges I
65 Ripley Hill Road
Barkhamsted, CT 06063

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Bridges I",'Barkhamsted=' + Barkhamsted.length); Bridgewater[Bridgewater.length] = createMarker(new GPoint(-73.36681366,41.53831863),"
Burnham School
80 Main St.
Bridgewater, CT 06752

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Burnham School",'Bridgewater=' + Bridgewater.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19580078,41.75130081),"
Center School
P.o. Box 110
Litchfield, CT 06778

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Center School",'Litchfield=' + Litchfield.length); Colebrook[Colebrook.length] = createMarker(new GPoint(-73.10900116,42.02109909),"
Colebrook Consolidated School
P.o. Box 9
Colebrook, CT 06021

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Colebrook Consolidated School",'Colebrook=' + Colebrook.length); West_Cornwall[West_Cornwall.length] = createMarker(new GPoint(-73.34190369,41.87601471),"
Cornwall Consolidated School
5 Cream Hill Rd.
West Cornwall, CT 06796

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Cornwall Consolidated School",'West_Cornwall=' + West_Cornwall.length); Washington[Washington.length] = createMarker(new GPoint(-73.30449677,41.60475159),"
Early Childhood Education Center
159 South Street
Washington, CT 06793

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Early Childhood Education Center",'Washington=' + Washington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.09337616,41.80926895),"
East School
215 Hogan Dr.
Torrington, CT 06790

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("East School",'Torrington=' + Torrington.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19747162,41.76250839),"
Education Connection Headstart Elementary School
P.o. Box 909
Litchfield, CT 06759

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Education Connection Headstart Elementary School",'Litchfield=' + Litchfield.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19336900,41.74677500),"
Education Connection Special Education
355 Goshen Rd.
Litchfield, CT 06759

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Education Connection Special Education",'Litchfield=' + Litchfield.length); Winsted[Winsted.length] = createMarker(new GPoint(-72.96150208,41.86880493),"
Explorations High School
71 Spencer Street
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Explorations High School",'Winsted=' + Winsted.length); Watertown[Watertown.length] = createMarker(new GPoint(-73.13107300,41.60294724),"
Fletcher W. Judson School
124 Hamilton Ln.
Watertown, CT 06795

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Fletcher W. Judson School",'Watertown=' + Watertown.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Flex
100 Battistoni Drive
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Flex",'Winsted=' + Winsted.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.13361359,41.81328583),"
Forbes School
500 Migeon Ave.
Torrington, CT 06790

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Forbes School",'Torrington=' + Torrington.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.07240295,41.92935562),"
Gilbert School
200 Williams Ave.
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Gilbert School",'Winsted=' + Winsted.length); Goshen[Goshen.length] = createMarker(new GPoint(-73.22911835,41.83580780),"
Goshen Center School
50 North St.
Goshen, CT 06756

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Goshen Center School",'Goshen=' + Goshen.length); Terryville[Terryville.length] = createMarker(new GPoint(-73.00575256,41.68269730),"
Harry S. Fisher School
79 North Main St.
Terryville, CT 06786

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Harry S. Fisher School",'Terryville=' + Terryville.length); Harwinton[Harwinton.length] = createMarker(new GPoint(-73.06975555,41.76960754),"
Harwinton Consolidated School
115 Litchfield Rd.
Harwinton, CT 06791

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Harwinton Consolidated School",'Harwinton=' + Harwinton.length); Watertown[Watertown.length] = createMarker(new GPoint(-73.11636353,41.60389328),"
Heminway Park School
37 Heminway Park Rd.
Watertown, CT 06795

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Heminway Park School",'Watertown=' + Watertown.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.43146515,41.53449249),"
Hill And Plain School
60 Old Town Park Rd.
New Milford, CT 06776

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Hill And Plain School",'New_Milford=' + New_Milford.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.22445679,41.72695541),"
Homebound
98 Wamogo Road
Litchfield, CT 06759

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Homebound",'Litchfield=' + Litchfield.length); Falls_Village[Falls_Village.length] = createMarker(new GPoint(-73.36309814,41.95450974),"
Housatonic Valley Regional High School
246 Warren Turnpike Rd
Falls Village, CT 06031

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Housatonic Valley Regional High School",'Falls_Village=' + Falls_Village.length); Norfolk[Norfolk.length] = createMarker(new GPoint(-73.19916900,41.98934900),"
Iep Program
128 Greenwoods Road
Norfolk, CT 06058

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Iep Program",'Norfolk=' + Norfolk.length); Woodbury[Woodbury.length] = createMarker(new GPoint(-73.20208740,41.55461884),"
Integrated Star Preschool Program
P.o. Box 469
Woodbury, CT 06798

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Integrated Star Preschool Program",'Woodbury=' + Woodbury.length); Morris[Morris.length] = createMarker(new GPoint(-73.18775177,41.68859100),"
James Morris School
10 East St.
Morris, CT 06763

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("James Morris School",'Morris=' + Morris.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.41416168,41.56589508),"
John Pettibone School
2 Pickett District Rd.
New Milford, CT 06776

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("John Pettibone School",'New_Milford=' + New_Milford.length); Oakville[Oakville.length] = createMarker(new GPoint(-73.09023285,41.60660934),"
John Trumbull Primary School
779 Buckingham St.
Oakville, CT 06779

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("John Trumbull Primary School",'Oakville=' + Oakville.length); Kent[Kent.length] = createMarker(new GPoint(-73.48056030,41.72417450),"
Kent Center School
P.o. Box 219
Kent, CT 06757

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Kent Center School",'Kent=' + Kent.length); Falls_Village[Falls_Village.length] = createMarker(new GPoint(-73.36309814,41.95450974),"
Lee H. Kellogg School
47 Main St.
Falls Village, CT 06031

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Lee H. Kellogg School",'Falls_Village=' + Falls_Village.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Links
100 Battistoni Drive
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Links",'Winsted=' + Winsted.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19580078,41.75130081),"
Litchfield High School
P.o. Box 110
Litchfield, CT 06759

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Litchfield High School",'Litchfield=' + Litchfield.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19580078,41.75130081),"
Litchfield Intermediate School
P.o. Box 110
Litchfield, CT 06759

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Litchfield Intermediate School",'Litchfield=' + Litchfield.length); Terryville[Terryville.length] = createMarker(new GPoint(-73.00117493,41.67892075),"
Main Street School
77 Main St.
Terryville, CT 06786

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Main Street School",'Terryville=' + Terryville.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.07445526,41.92690659),"
Mary P. Hinsdale School
15 Hinsdale Ave.
Winsted, CT 06098

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Mary P. Hinsdale School",'Winsted=' + Winsted.length); Woodbury[Woodbury.length] = createMarker(new GPoint(-73.20932007,41.54742813),"
Mitchell Elementary School
14 School St.
Woodbury, CT 06798

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Mitchell Elementary School",'Woodbury=' + Woodbury.length); New_Hartford[New_Hartford.length] = createMarker(new GPoint(-72.96746826,41.87704468),"
New Hartford Elementary School
40 Wickett St.
New Hartford, CT 06057

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("New Hartford Elementary School",'New_Hartford=' + New_Hartford.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.41590881,41.56835175),"
New Milford High School
388 Danbury Rd.
New Milford, CT 06776

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("New Milford High School",'New_Milford=' + New_Milford.length); Woodbury[Woodbury.length] = createMarker(new GPoint(-73.18839264,41.55689240),"
Nonnewaug High School
P.o. Box 469
Woodbury, CT 06798

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Nonnewaug High School",'Woodbury=' + Woodbury.length); North_Canaan[North_Canaan.length] = createMarker(new GPoint(-73.33371735,42.03129578),"
North Canaan Elementary School
P.o. Box 758 90 Pease
North Canaan, CT 06018

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("North Canaan Elementary School",'North_Canaan=' + North_Canaan.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.39297485,41.61985779),"
Northville Elementary School
22 Hipp Rd.
New Milford, CT 06776

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Northville Elementary School",'New_Milford=' + New_Milford.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.04772949,41.91430283),"
Northwestern Regional High School
100 Battistoni Dr.
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Northwestern Regional High School",'Winsted=' + Winsted.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.07530212,41.93080139),"
Northwestern Regional Middle School
100 Battistoni Dr.
Winsted, CT 06098

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Northwestern Regional Middle School",'Winsted=' + Winsted.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.11174774,41.81016922),"
Oliver Wolcott Vocational School
75 Oliver St.
Torrington, CT 06790

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Oliver Wolcott Vocational School",'Torrington=' + Torrington.length); Winchester[Winchester.length] = createMarker(new GPoint(-73.06624603,41.92649841),"
Pearson Middle School
2 Wetmore Ave.
Winchester, CT 06098

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Pearson Middle School",'Winchester=' + Winchester.length); Plymouth[Plymouth.length] = createMarker(new GPoint(-73.05315399,41.67859650),"
Plymouth Center School
107 North St.
Plymouth, CT 06782

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Plymouth Center School",'Plymouth=' + Plymouth.length); Oakville[Oakville.length] = createMarker(new GPoint(-73.08544922,41.59844589),"
Polk School
435 Buckingham St.
Oakville, CT 06779

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Polk School",'Oakville=' + Oakville.length); Terryville[Terryville.length] = createMarker(new GPoint(-73.01261902,41.67976379),"
Prospect Street School
12 Prospect St.
Terryville, CT 06786

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Prospect Street School",'Terryville=' + Terryville.length); Lakeville[Lakeville.length] = createMarker(new GPoint(-73.44020844,41.96386719),"
Salisbury Central School
P.o. Box 1808 45 Linc
Lakeville, CT 06039

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Salisbury Central School",'Lakeville=' + Lakeville.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.41794586,41.56796265),"
Sarah Noble Intermediate School
25 Sunny Valley Rd.
New Milford, CT 06776

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Sarah Noble Intermediate School",'New_Milford=' + New_Milford.length); New_Milford[New_Milford.length] = createMarker(new GPoint(-73.39279175,41.61985779),"
Schaghticoke Middle School
23 Hipp Rd.
New Milford, CT 06776

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Schaghticoke Middle School",'New_Milford=' + New_Milford.length); Barkhamsted[Barkhamsted.length] = createMarker(new GPoint(-72.99138600,41.91153200),"
Shared Services Integrated Preschool
65 Ripley Hill Road
Barkhamsted, CT 06063

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Shared Services Integrated Preschool",'Barkhamsted=' + Barkhamsted.length); Sharon[Sharon.length] = createMarker(new GPoint(-73.47177100,41.88323500),"
Sharon Center School
80 Hilltop Rd.
Sharon, CT 06069

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Sharon Center School",'Sharon=' + Sharon.length); Washington[Washington.length] = createMarker(new GPoint(-73.30455017,41.60499573),"
Shepaug Valley High School
157 South St.
Washington, CT 06793

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Shepaug Valley High School",'Washington=' + Washington.length); Washington[Washington.length] = createMarker(new GPoint(-73.30449677,41.60475159),"
Shepaug Valley Middle School
159 South St.
Washington, CT 06793

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Shepaug Valley Middle School",'Washington=' + Washington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.11334229,41.79378510),"
Southeast School
196 Oak Ave.
Torrington, CT 06790

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Southeast School",'Torrington=' + Torrington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.13361359,41.81328583),"
Southwest School
340 Litchfield Street
Torrington, CT 06790

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Southwest School",'Torrington=' + Torrington.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06927900,41.92109500),"
Step
100 Battistoni Drive
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Step",'Winsted=' + Winsted.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.19336900,41.74677500),"
Stepping Stones Preschool Program
98 Wamogo Road
Litchfield, CT 06759

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Stepping Stones Preschool Program",'Litchfield=' + Litchfield.length); Oakville[Oakville.length] = createMarker(new GPoint(-73.09254456,41.58499146),"
Swift Middle School
250 Colonial St.
Oakville, CT 06779

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Swift Middle School",'Oakville=' + Oakville.length); Terryville[Terryville.length] = createMarker(new GPoint(-73.00904846,41.67949677),"
Terryville High School
21 North Main St.
Terryville, CT 06786

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Terryville High School",'Terryville=' + Terryville.length); Thomaston[Thomaston.length] = createMarker(new GPoint(-73.07451630,41.67356110),"
Thomaston Center School
1 Thomas Ave.
Thomaston, CT 06787

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Thomaston Center School",'Thomaston=' + Thomaston.length); Thomaston[Thomaston.length] = createMarker(new GPoint(-73.09631348,41.65851974),"
Thomaston High School
185 Branch Rd.
Thomaston, CT 06787

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Thomaston High School",'Thomaston=' + Thomaston.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.09237671,41.81905365),"
Torringford School
631 Torringford West S
Torrington, CT 06790

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Torringford School",'Torrington=' + Torrington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.11119080,41.81505585),"
Torrington High School
50 Major Besse Dr.
Torrington, CT 06790

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Torrington High School",'Torrington=' + Torrington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.07637787,41.83702850),"
Torrington Middle School
200 Middle School Rd.
Torrington, CT 06790

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Torrington Middle School",'Torrington=' + Torrington.length); Torrington[Torrington.length] = createMarker(new GPoint(-73.12245941,41.80378723),"
Vogel-wetmore School
68 Church St.
Torrington, CT 06790

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Vogel-wetmore School",'Torrington=' + Torrington.length); Litchfield[Litchfield.length] = createMarker(new GPoint(-73.22445679,41.72695541),"
Wamogo Regional High School
98 Wamogo Rd.
Litchfield, CT 06759

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Wamogo Regional High School",'Litchfield=' + Litchfield.length); Warren[Warren.length] = createMarker(new GPoint(-73.34313202,41.73044205),"
Warren Elementary School
21 Sackett Hill Rd.
Warren, CT 06754

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Warren Elementary School",'Warren=' + Warren.length); Washington_Dep[Washington_Dep.length] = createMarker(new GPoint(-73.31822205,41.63967896),"
Washington Primary School
11 School St.
Washington Dep, CT 06794

[ View School Profile ]
",iconRd); mySelect.options[mySelect.options.length] = new Option("Washington Primary School",'Washington_Dep=' + Washington_Dep.length); Watertown[Watertown.length] = createMarker(new GPoint(-73.10175323,41.59710693),"
Watertown High School
324 French St.
Watertown, CT 06795

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Watertown High School",'Watertown=' + Watertown.length); Winsted[Winsted.length] = createMarker(new GPoint(-73.06539154,41.92301941),"
Winchester Alternate High School
79 Gay St.
Winsted, CT 06098

[ View School Profile ]
",iconGr); mySelect.options[mySelect.options.length] = new Option("Winchester Alternate High School",'Winsted=' + Winsted.length); Woodbury[Woodbury.length] = createMarker(new GPoint(-73.20993805,41.54921722),"
Woodbury Middle School
67 Washington Ave.
Woodbury, CT 06798

[ View School Profile ]
",iconBl); mySelect.options[mySelect.options.length] = new Option("Woodbury Middle School",'Woodbury=' + Woodbury.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,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(Barkhamsted); map.removeOverlays(Bethlehem); map.removeOverlays(Bridgewater); map.removeOverlays(Colebrook); map.removeOverlays(Falls_Village); map.removeOverlays(Goshen); map.removeOverlays(Harwinton); map.removeOverlays(Kent); map.removeOverlays(Lakeville); map.removeOverlays(Litchfield); map.removeOverlays(Morris); map.removeOverlays(New_Hartford); map.removeOverlays(New_Milford); map.removeOverlays(Norfolk); map.removeOverlays(North_Canaan); map.removeOverlays(Oakville); map.removeOverlays(Plymouth); map.removeOverlays(Roxbury); map.removeOverlays(Sharon); map.removeOverlays(Terryville); map.removeOverlays(Thomaston); map.removeOverlays(Torrington); map.removeOverlays(Warren); map.removeOverlays(Washington); map.removeOverlays(Washington_Dep); map.removeOverlays(Watertown); map.removeOverlays(West_Cornwall); map.removeOverlays(Winchester); map.removeOverlays(Winsted); map.removeOverlays(Woodbury); 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(Winsted);map.removeOverlays(Barkhamsted); map.removeOverlays(Bethlehem); map.removeOverlays(Bridgewater); map.removeOverlays(Colebrook); map.removeOverlays(Falls_Village); map.removeOverlays(Goshen); map.removeOverlays(Harwinton); map.removeOverlays(Kent); map.removeOverlays(Lakeville); map.removeOverlays(Litchfield); map.removeOverlays(Morris); map.removeOverlays(New_Hartford); map.removeOverlays(New_Milford); map.removeOverlays(Norfolk); map.removeOverlays(North_Canaan); map.removeOverlays(Oakville); map.removeOverlays(Plymouth); map.removeOverlays(Roxbury); map.removeOverlays(Sharon); map.removeOverlays(Terryville); map.removeOverlays(Thomaston); map.removeOverlays(Torrington); map.removeOverlays(Warren); map.removeOverlays(Washington); map.removeOverlays(Washington_Dep); map.removeOverlays(Watertown); map.removeOverlays(West_Cornwall); map.removeOverlays(Winchester); map.removeOverlays(Winsted); map.removeOverlays(Woodbury); map.addOverlays(Barkhamsted); centerByArray(Barkhamsted, false, false); cntMarker += Barkhamsted.length; map.addOverlays(Bethlehem); centerByArray(Bethlehem, false, false); cntMarker += Bethlehem.length; map.addOverlays(Bridgewater); centerByArray(Bridgewater, false, false); cntMarker += Bridgewater.length; map.addOverlays(Colebrook); centerByArray(Colebrook, false, false); cntMarker += Colebrook.length; map.addOverlays(Falls_Village); centerByArray(Falls_Village, false, false); cntMarker += Falls_Village.length; map.addOverlays(Goshen); centerByArray(Goshen, false, false); cntMarker += Goshen.length; map.addOverlays(Harwinton); centerByArray(Harwinton, false, false); cntMarker += Harwinton.length; map.addOverlays(Kent); centerByArray(Kent, false, false); cntMarker += Kent.length; map.addOverlays(Lakeville); centerByArray(Lakeville, false, false); cntMarker += Lakeville.length; map.addOverlays(Litchfield); centerByArray(Litchfield, false, false); cntMarker += Litchfield.length; map.addOverlays(Morris); centerByArray(Morris, false, false); cntMarker += Morris.length; map.addOverlays(New_Hartford); centerByArray(New_Hartford, false, false); cntMarker += New_Hartford.length; map.addOverlays(New_Milford); centerByArray(New_Milford, false, false); cntMarker += New_Milford.length; map.addOverlays(Norfolk); centerByArray(Norfolk, false, false); cntMarker += Norfolk.length; map.addOverlays(North_Canaan); centerByArray(North_Canaan, false, false); cntMarker += North_Canaan.length; map.addOverlays(Oakville); centerByArray(Oakville, false, false); cntMarker += Oakville.length; map.addOverlays(Plymouth); centerByArray(Plymouth, false, false); cntMarker += Plymouth.length; map.addOverlays(Roxbury); centerByArray(Roxbury, false, false); cntMarker += Roxbury.length; map.addOverlays(Sharon); centerByArray(Sharon, false, false); cntMarker += Sharon.length; map.addOverlays(Terryville); centerByArray(Terryville, false, false); cntMarker += Terryville.length; map.addOverlays(Thomaston); centerByArray(Thomaston, false, false); cntMarker += Thomaston.length; map.addOverlays(Torrington); centerByArray(Torrington, false, false); cntMarker += Torrington.length; map.addOverlays(Warren); centerByArray(Warren, false, false); cntMarker += Warren.length; map.addOverlays(Washington); centerByArray(Washington, false, false); cntMarker += Washington.length; map.addOverlays(Washington_Dep); centerByArray(Washington_Dep, false, false); cntMarker += Washington_Dep.length; map.addOverlays(Watertown); centerByArray(Watertown, false, false); cntMarker += Watertown.length; map.addOverlays(West_Cornwall); centerByArray(West_Cornwall, false, false); cntMarker += West_Cornwall.length; map.addOverlays(Winchester); centerByArray(Winchester, false, false); cntMarker += Winchester.length; map.addOverlays(Winsted); centerByArray(Winsted, false, false); cntMarker += Winsted.length; map.addOverlays(Woodbury); centerByArray(Woodbury, false, false); cntMarker += Woodbury.length; centerByArray(Winsted,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'); } }