//= y)) || ((this.getVertex(j).lat() < y) && (this.getVertex(i).lat() >= y)) ) { if ( this.getVertex(i).lng() + (y - this.getVertex(i).lat()) / (this.getVertex(j).lat()-this.getVertex(i).lat()) * (this.getVertex(j).lng() - this.getVertex(i).lng())"; popHTML += "
"; popHTML += ""; popHTML += "
Want to Save up to $600
"; popHTML += "
on Auto Insurance
"; popHTML += "
in " + "Montana" + "?
"; popHTML += "
Enter your Zip Code:
"; popHTML += ""; popHTML += "
"; var map = new GMap2(document.getElementById("map")); var topRight = new GControlPosition(G_ANCHOR_TOP_RIGHT, new GSize(0,0)); map.addControl(new GSmallMapControl()); map.addControl(new GMapTypeControl(),topRight); map.addControl(new GOverviewMapControl(), new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(5, 5))); var center = new GLatLng(46.904800,-110.326100); //new GLatLng(47.391700,-121.570800); map.setCenter(center,5); myIcon = new GIcon(); // marker image myIcon.image ="http://www.autoquotenow.com/images/marker.png"; myIcon.iconSize = new GSize(45, 17); myIcon.iconAnchor = new GPoint(45, 17); myIcon.infoWindowAnchor = new GPoint(43,17); var marker = new GMarker(center, myIcon) map.addOverlay(marker); var myEvent = GEvent.addListener(marker,"mouseover", function() { marker.openInfoWindowHtml(popHTML); map.panTo(new GLatLng(48.904800,-110.326100)); // GEvent.removeListener(myEvent); }); var label = "Montana"; var color = "#88ff00"; var pts = []; pts[0] = new GLatLng (44.4750,-111.0512); pts[1] = new GLatLng (44.7311,-111.3684); pts[2] = new GLatLng (44.6198,-111.5071); pts[3] = new GLatLng (44.5386,-111.4673); pts[4] = new GLatLng (44.5151,-111.8285); pts[5] = new GLatLng (44.5592,-111.8848); pts[6] = new GLatLng (44.5229,-112.1127); pts[7] = new GLatLng (44.5367,-112.3270); pts[8] = new GLatLng (44.4475,-112.3901); pts[9] = new GLatLng (44.4896,-112.7293); pts[10] = new GLatLng (44.4181,-112.8296); pts[11] = new GLatLng (44.3563,-112.8529); pts[12] = new GLatLng (44.4857,-113.0205); pts[13] = new GLatLng (44.5905,-113.0713); pts[14] = new GLatLng (44.7389,-113.1152); pts[15] = new GLatLng (44.8091,-113.2471); pts[16] = new GLatLng (44.7887,-113.3459); pts[17] = new GLatLng (44.9386,-113.4970); pts[18] = new GLatLng (45.0269,-113.4229); pts[19] = new GLatLng (45.2749,-113.7085); pts[20] = new GLatLng (45.4447,-113.7964); pts[21] = new GLatLng (45.6140,-113.8403); pts[22] = new GLatLng (45.6908,-113.9722); pts[23] = new GLatLng (45.5631,-114.1315); pts[24] = new GLatLng (45.5525,-114.2358); pts[25] = new GLatLng (45.4592,-114.3347); pts[26] = new GLatLng (45.5439,-114.4652); pts[27] = new GLatLng (45.5583,-114.5668); pts[28] = new GLatLng (45.6755,-114.5215); pts[29] = new GLatLng (45.7733,-114.5641); pts[30] = new GLatLng (45.8613,-114.4391); pts[31] = new GLatLng (45.9989,-114.4817); pts[32] = new GLatLng (46.1237,-114.5132); pts[33] = new GLatLng (46.2577,-114.4652); pts[34] = new GLatLng (46.3441,-114.4171); pts[35] = new GLatLng (46.4530,-114.3896); pts[36] = new GLatLng (46.5069,-114.3484); pts[37] = new GLatLng (46.6504,-114.3279); pts[38] = new GLatLng (46.6334,-114.4652); pts[39] = new GLatLng (46.6362,-114.5929); pts[40] = new GLatLng (46.7003,-114.7659); pts[41] = new GLatLng (46.8423,-114.9307); pts[42] = new GLatLng (47.0402,-115.1147); pts[43] = new GLatLng (47.1888,-115.2933); pts[44] = new GLatLng (47.2569,-115.3290); pts[45] = new GLatLng (47.3025,-115.5267); pts[46] = new GLatLng (47.4253,-115.7547); pts[47] = new GLatLng (47.5487,-115.7533); pts[48] = new GLatLng (47.5793,-115.6956); pts[49] = new GLatLng (47.9771,-116.0458); pts[50] = new GLatLng (48.9991,-116.0458); pts[51] = new GLatLng (48.9991,-104.0501); pts[52] = new GLatLng (45.0269,-104.0186); pts[53] = new GLatLng (45.0153,-104.0186); pts[54] = new GLatLng (44.9978,-104.0199); pts[55] = new GLatLng (44.9959,-111.0498); pts[56] = new GLatLng (44.4750,-111.0512); var poly = new GPolygon(pts,"#333399",3,1,color,.1); polys.push(poly); labels.push(label); map.addOverlay(poly); } else { alert("Sorry, Google Maps is not compatible with this browser."); } } //]]>