-
Notifications
You must be signed in to change notification settings - Fork 1
/
wtd_banner.html
286 lines (245 loc) · 11.3 KB
/
wtd_banner.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<link href="http://www.kingcounty.gov/style/kcAgencies.css" type="text/css" rel="stylesheet" />
<title>WTD Facility Locator for Storm Event</title>
<meta name="Author" content="" />
<meta name="lastReviewedDate" content="October 1, 2007" />
<meta runat="server" id="MetaKeywords" name="Keywords" content="King, County, Government, Business, Court, code, law, Election, Environment, Health, Property, Records, archives, licenses, certificates, recreation, leisure, police, deputy, safety, emergency, emergencies, social, service, transportation, bus, transit, parks, Sims, Ron" />
<meta runat="server" id="MetaDescription" name="Description" content="Discretionary Web Application" />
<meta name="language" content="en-US" />
<meta name="govType" content="County" />
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
<META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE">
</head>
<body class="tundra">
<!-- begin of header -->
<div id="header">
<div id="kclogo">
<div id="logo">
<a href="http://www.kingcounty.gov" title="King County home">
<img src="http://www.kingcounty.gov/style/kcBaseImages/kc-logo.gif" alt="King County - Always at your service"
border="0" /></a></div>
<br />
</div>
<ul id="topnav">
<li class="first"><a class="kcBaseTopNavItem" href="http://www.kingcounty.gov/">Home</a></li>
<li class="menuitem"><a class="kcBaseTopNavItem" href="http://your.kingcounty.gov/news/">
News</a></li>
<li class="menuitem"><a class="kcBaseTopNavItem" href="http://your.kingcounty.gov/services.htm">
Services</a></li>
<li class="menuitem"><a class="kcBaseTopNavItem" href="http://directory.kingcounty.gov/">
Directory</a></li>
<li class="last"><a class="kcBaseTopNavItem" href="http://info.kingcounty.gov/about/contact/default.aspx">
Contact</a></li>
</ul>
<div id="searchbox">
<form method="get" id="seek" name="seek" action="http://search.kingcounty.gov/search">
<input maxlength="100" name="q" size="" class="textbox" />
<input type="submit" name="btnG" value="Search" class="submit" />
<input type="hidden" name="site" value="w" />
<input type="hidden" name="client" value="w_frontend" />
<input type="hidden" name="output" value="xml_no_dtd" />
<input type="hidden" name="proxystylesheet" value="w_frontend" />
</form>
</div>
<div id="funcs">
<div id="sitemap">
<a href="http://www.kingcounty.gov/environment/wtd.aspx">SITEMAP </a>
</div>
</div>
<div id="sitename">
<a href="http://www.kingcounty.gov/environment/wtd.aspx">Wastewater Treatment Division</a></div>
<div id="sitesubname">
</div>
</div>
<!-- end of header -->
<div id="breadcrumbs" style="margin-bottom: 5px">
<strong>You're in</strong>: <a href="http://www.kingcounty.gov/environment/wtd.aspx/" title="Wastewater Treatment Division"
class="crumb">Wastewater Treatment</a> » <a href="http://www.kingcounty.gov/environment/wtd.aspx"
title="WTD" class="crumb"> </a> » <span class="crumb">Facility Locator</span></div>
<!-- <form id="form1" runat="server">
<div id="contentcol">
<strong>We apologize… </strong>
<br />
<br />
The Road Alert map is currently unavailable due to technical problems.
<br />
<br />
Please view a <a href="http://your.kingcounty.gov/kcdot/roads/roadalert/">text list</a>
of road closures and conditions while we work to fix the problem.
<br />
<br />
If you wish to contact us, please send us an <a href="mailto:[email protected]">
e-mail</a>. Thank you for your patience.<br />
<br />
-->
Please type in location address<br />
</div>
</form>
<title>WTD Facility Locator GMap</title>
<script src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAATMauu7LQ2m5n1BQbcicRtxQ08Zr_QFRKfJuuGt4Q0XaoiVJAphQIAvA0aemQog_XG5cogGbdOv_Quw"
type="text/javascript"></script>
<script src="http://serverapi.arcgisonline.com/jsapi/gmaps/?v=1.2" type="text/javascript" ></script>
<body onunload="GUnload()">
<!-- Place where you enter address to geocode -->
<form action="#" onsubmit="showAddress(this.address.value); return false">
<p>
<input type="text" size="60" name="address" value="201 S Jackson St, Seattle, WA" />
<input type="submit" value="Go!" />
</p>
</form>
<!-- you can use tables or divs for the overall layout -->
<table border=1>
<tr>
<td>
<div id="map" style="width: 750px; height: 600px"></div>
</td>
<td width = 175 valign="top" style="text-decoration: underline; color: #4444ff;">
<div id="sidebar" style="overflow:auto; height:450px;"></div>
</td>
</tr>
</table>
<noscript><b>JavaScript must be enabled in order for you to use Google Maps.</b>
However, it seems JavaScript is either disabled or not supported by your browser.
To view Google Maps, enable JavaScript by changing your browser options, and then
try again.
</noscript>
<script type="text/javascript">
//<![CDATA[
if (GBrowserIsCompatible()) {
// this variable will collect the html which will eventualkly be placed in the sidebar
var sidebar_html = "";
// arrays to hold copies of the markers and html used by the sidebar
// because the function closure trick doesnt work there
var gmarkers = [];
var htmls = [];
var i = 0;
// A function to create the marker and set up the event window
function createMarker(point,name,html) {
var marker = new GMarker(point, baseIcon);
GEvent.addListener(marker, "click", function() {
marker.openInfoWindowHtml(html);
});
// save the info we need to use later for the sidebar
gmarkers[i] = marker;
htmls[i] = html;
// add a line to the sidebar html
sidebar_html += '<a href="javascript:myclick(' + i + ')">' + name + '</a><br>';
i++;
return marker;
}
// This function picks up the click and opens the corresponding info window
function myclick(i) {
gmarkers[i].openInfoWindowHtml(htmls[i]);
}
// create the map
var map = new GMap2(document.getElementById("map"));
//===creating customized icon=============
var baseIcon = new GIcon();
baseIcon.image = "large_green_marker.png";
baseIcon.shadow = "large_shadow.png";
baseIcon.iconSize = new GSize(12, 20);
baseIcon.shadowSize = new GSize(22, 20);
baseIcon.iconAnchor = new GPoint(6, 20);
baseIcon.infoWindowAnchor = new GPoint(5, 1);
baseIcon.infoShadowAnchor = new GPoint(18, 25);
//===============creating geocoding service==========
var geocoder = new GClientGeocoder();
function showAddress(address) {
geocoder.getLatLng(
address,
function(point) {
if (!point) {
alert(address + " not found");
} else {
map.setCenter(point, 11);
var marker = new GMarker(point);
map.addOverlay(marker);
marker.openInfoWindowHtml(address);
}
}
);
}
//====restricting the range of zoom levels=====
//get the list of map types
var mt = map.getMapTypes();
//overwrite the getMinimumResolution() and getMaxiumResolution()methods
for (var i=0; i<mt.length; i++) {
mt[i].getMinimumResolution = function() {return 11;}
mt[i].getMaximumResolution = function() {return 19;}
}
map.removeMapType (G_SATELLITE_MAP);
map.addMapType (G_PHYSICAL_MAP);
var mapControl = new GMapTypeControl ();
map.addControl (mapControl);
//map.setMapType (G_PHYSICAL_MAP);
map.addControl(new GLargeMapControl());
map.addControl(new GMapTypeControl());
map.addControl(new GOverviewMapControl());
map.addControl(new GScaleControl());
map.setCenter(new GLatLng(47.598287,-122.33698), 10);
// center the map and set the zoom level (10)
//create mapextension class to be used to add/remove results from the map.
mapExtension = new esri.arcgis.gmaps.MapExtension(map);
//create mapOptions to specify opacity, minResolution, maxResolution when adding to the map.
var mapOptions = {opacity: 0.85, minResolution:0, maxResolution: 19};
//create custom tile layer
var tiledmap = new esri.arcgis.gmaps.TiledMapServiceLayer("http://cragsdev/arcgis/rest/services/keum/wtdmashup_20121107/MapServer", mapOptions, addTiledMap);
function addTiledMap(gTileLayer) {
//Add tile layer as a GTileLayerOverlay using mapExtension
gOverlays = mapExtension.addToMap(gTileLayer);
}
// Read the data from example.xml
var request = GXmlHttp.create();
request.open("GET", "wtd_facility.xml", true);
request.onreadystatechange = function() {
if (request.readyState == 4) {
var xmlDoc = request.responseXML;
// obtain the array of markers and loop through it
var markers = xmlDoc.documentElement.getElementsByTagName("marker");
for (var i = 0; i < markers.length; i++) {
// obtain the attribues of each marker
var lat = parseFloat(markers[i].getAttribute("lat"));
var lng = parseFloat(markers[i].getAttribute("lng"));
var point = new GLatLng(lat,lng);
var html = markers[i].getAttribute("html");
var label = markers[i].getAttribute("label");
// create the marker
var marker = createMarker(point,label,html);
map.addOverlay(marker);
}
// put the assembled sidebar_html contents into the sidebar div
document.getElementById("sidebar").innerHTML = sidebar_html;
}
}
request.send(null);
}
else {
alert("Sorry, the Google Maps API is not compatible with this browser");
}
// This Javascript is based on code provided by the
// Blackpool Community Church Javascript Team with modification done by
// WTD GIS Peter Keum
//]]>
</script>
<table border="0" cellspacing="0" cellpadding="0" width="700">
<tr>
<td width="40%" valign="top"><p class="p70">Powered by <a href="http://www.google.com/apis/maps/">Google Maps API</a>.</p></td>
<td valign="top"><p align="right" class="smlb">View Facility list in <a href="basicFacility.xml">Tabular Format</a>. </p></td>
</tr>
<tr>
<td colspan="2" valign="top">
<br>
</br>
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-7435060-1");
pageTracker._trackPageview();
} catch(err) {}</script>
</body>
</html>