-
Notifications
You must be signed in to change notification settings - Fork 5
/
lecture_all_linked.html
5349 lines (5347 loc) · 510 KB
/
lecture_all_linked.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
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang="">
<head>
<meta charset="utf-8" />
<meta name="generator" content="pandoc" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
<meta name="author" content="Karl Benedict" />
<title>Geography 485L/585L - Internet Mapping</title>
<style type="text/css">
code{white-space: pre-wrap;}
span.smallcaps{font-variant: small-caps;}
span.underline{text-decoration: underline;}
div.column{display: inline-block; vertical-align: top; width: 50%;}
</style>
<style type="text/css">
a.sourceLine { display: inline-block; line-height: 1.25; }
a.sourceLine { pointer-events: none; color: inherit; text-decoration: inherit; }
a.sourceLine:empty { height: 1.2em; position: absolute; }
.sourceCode { overflow: visible; }
code.sourceCode { white-space: pre; position: relative; }
div.sourceCode { margin: 1em 0; }
pre.sourceCode { margin: 0; }
@media screen {
div.sourceCode { overflow: auto; }
}
@media print {
code.sourceCode { white-space: pre-wrap; }
a.sourceLine { text-indent: -1em; padding-left: 1em; }
}
pre.numberSource a.sourceLine
{ position: relative; }
pre.numberSource a.sourceLine:empty
{ position: absolute; }
pre.numberSource a.sourceLine::before
{ content: attr(data-line-number);
position: absolute; left: -5em; text-align: right; vertical-align: baseline;
border: none; pointer-events: all;
-webkit-touch-callout: none; -webkit-user-select: none;
-khtml-user-select: none; -moz-user-select: none;
-ms-user-select: none; user-select: none;
padding: 0 4px; width: 4em;
color: #aaaaaa;
}
pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; }
div.sourceCode
{ }
@media screen {
a.sourceLine::before { text-decoration: underline; }
}
code span.al { color: #ff0000; font-weight: bold; } /* Alert */
code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
code span.at { color: #7d9029; } /* Attribute */
code span.bn { color: #40a070; } /* BaseN */
code span.bu { } /* BuiltIn */
code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
code span.ch { color: #4070a0; } /* Char */
code span.cn { color: #880000; } /* Constant */
code span.co { color: #60a0b0; font-style: italic; } /* Comment */
code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
code span.do { color: #ba2121; font-style: italic; } /* Documentation */
code span.dt { color: #902000; } /* DataType */
code span.dv { color: #40a070; } /* DecVal */
code span.er { color: #ff0000; font-weight: bold; } /* Error */
code span.ex { } /* Extension */
code span.fl { color: #40a070; } /* Float */
code span.fu { color: #06287e; } /* Function */
code span.im { } /* Import */
code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
code span.kw { color: #007020; font-weight: bold; } /* Keyword */
code span.op { color: #666666; } /* Operator */
code span.ot { color: #007020; } /* Other */
code span.pp { color: #bc7a00; } /* Preprocessor */
code span.sc { color: #4070a0; } /* SpecialChar */
code span.ss { color: #bb6688; } /* SpecialString */
code span.st { color: #4070a0; } /* String */
code span.va { color: #19177c; } /* Variable */
code span.vs { color: #4070a0; } /* VerbatimString */
code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
</style>
<link rel="stylesheet" href="page.css">
<!--[if lt IE 9]>
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
<![endif]-->
</head>
<body>
<header>
<h1 class="title">Geography 485L/585L - Internet Mapping</h1>
<p class="author">Karl Benedict</p>
<p class="date">Spring 2018</p>
</header>
<nav id="TOC">
<ul>
<li><a href="#week-1---module-1---introduction-and-outline">Week 1 - Module 1 - Introduction and Outline</a><ul>
<li><a href="#overview">Overview</a></li>
<li><a href="#introductions">Introductions</a></li>
<li><a href="#syllabus-review-link">Syllabus Review (<a href="https://karlbenedict.github.io/GEOG485-585/syllabus.pdf">link</a>)</a><ul>
<li><a href="#class-topics">Class Topics</a></li>
</ul></li>
<li><a href="#basics">Basics</a><ul>
<li><a href="#outline">Outline</a></li>
<li><a href="#what-is-internet-mapping">What is Internet Mapping</a></li>
<li><a href="#definitions">Definitions</a></li>
</ul></li>
<li><a href="#tools">Tools</a><ul>
<li><a href="#computer-hardware-requirements">Computer Hardware Requirements</a></li>
<li><a href="#software-requirements">Software Requirements</a></li>
</ul></li>
</ul></li>
<li><a href="#week-2---module-2a---web-based-mapping-clients.-html-css-javascript">Week 2 - Module 2a - Web-based Mapping Clients. HTML, CSS & Javascript</a><ul>
<li><a href="#overview-1">Overview</a></li>
<li><a href="#web-development">Web Development</a></li>
<li><a href="#parts-of-a-web-page">Parts of a Web Page</a></li>
<li><a href="#web-site-components---structure">Web Site Components - Structure</a></li>
<li><a href="#web-site-components---presentation">Web Site Components - Presentation</a></li>
<li><a href="#css-selectors">CSS Selectors</a></li>
<li><a href="#web-site-components---behavior">Web Site Components - Behavior</a></li>
<li><a href="#reference-links">Reference Links</a></li>
<li><a href="#simple-web-page">Simple Web Page</a></li>
<li><a href="#simple-web-page-with-css">Simple Web Page with CSS</a></li>
<li><a href="#simple-web-page-with-javascript">Simple Web Page with Javascript</a></li>
</ul></li>
<li><a href="#week-3--module-2a---web-based-mapping-clients.-google-maps-api">Week 3- Module 2a - Web-based Mapping Clients. Google Maps API</a><ul>
<li><a href="#outline-1">Outline</a></li>
<li><a href="#what-is-an-api">What is an API</a></li>
<li><a href="#google-maps-api-version">Google Maps API Version</a></li>
<li><a href="#reference-information">Reference Information</a></li>
<li><a href="#key-components">Key Components</a></li>
<li><a href="#controls">Controls</a></li>
<li><a href="#overlays">Overlays</a></li>
<li><a href="#services">Services</a></li>
<li><a href="#events">Events</a></li>
<li><a href="#examples">Examples</a></li>
<li><a href="#simple---roadmap">Simple - Roadmap</a></li>
<li><a href="#simple---roadmap-code">Simple - Roadmap Code</a></li>
<li><a href="#simple---satellite">Simple - Satellite</a></li>
<li><a href="#simple---satellite-code">Simple - Satellite Code</a></li>
<li><a href="#simple---hybrid">Simple - Hybrid</a></li>
<li><a href="#simple---hybrid-code">Simple - Hybrid Code</a></li>
<li><a href="#simple---terrain">Simple - Terrain</a></li>
<li><a href="#simple---terrain-code">Simple - Terrain Code</a></li>
<li><a href="#simple---hybrid---zoomed">Simple - Hybrid - Zoomed</a></li>
<li><a href="#simple---hybrid---zoomed-code">Simple - Hybrid - Zoomed Code</a></li>
<li><a href="#simple---zoomed---modified-controls">Simple - Zoomed - Modified Controls</a></li>
<li><a href="#simple---zoomed---modified-controls-code">Simple - Zoomed - Modified Controls Code</a></li>
<li><a href="#markers">Markers</a></li>
<li><a href="#markers-code">Markers Code</a></li>
<li><a href="#polyline">Polyline</a></li>
<li><a href="#polyline-code">Polyline Code</a></li>
<li><a href="#polygon">Polygon</a></li>
<li><a href="#polygon-code">Polygon Code</a></li>
<li><a href="#adding-an-info-window">Adding an Info Window</a></li>
<li><a href="#adding-an-info-window-code">Adding an Info Window Code</a></li>
</ul></li>
<li><a href="#week-4---module-2a---web-based-mapping-clients.-google-maps-api-pt.-2">Week 4 - Module 2a - Web-based Mapping Clients. Google Maps API (pt. 2)</a><ul>
<li><a href="#overview-2">Overview</a></li>
<li><a href="#getting-started-with-styled-maps"><em>Getting Started with Styled Maps</em></a></li>
<li><a href="#map-example-simple---styled">Map Example: Simple - Styled</a></li>
<li><a href="#google-fusion-tables">Google Fusion Tables</a></li>
<li><a href="#bringing-it-all-together---link">Bringing It All Together - <a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/gmaps_events.html">link</a></a></li>
</ul></li>
<li><a href="#week-5---module-3---gis-and-services-oriented-architectures">Week 5 - Module 3 - GIS and Services Oriented Architectures</a><ul>
<li><a href="#overview-3">Overview</a></li>
<li><a href="#geographic-information-systems">Geographic Information Systems</a><ul>
<li><a href="#data-types---vector">Data Types - Vector</a></li>
<li><a href="#data-types---raster">Data Types - Raster</a></li>
<li><a href="#accessing-and-processing-raster-and-vector-data">Accessing and Processing Raster and Vector Data</a></li>
<li><a href="#accessing-and-processing-raster-and-vector-data---programmatically">Accessing and Processing Raster and Vector Data - Programmatically</a></li>
<li><a href="#coordinate-systemsprojections">Coordinate Systems/Projections</a></li>
<li><a href="#epsg-codes">EPSG Codes</a></li>
<li><a href="#projection-parameters">Projection Parameters</a></li>
</ul></li>
<li><a href="#services-oriented-architectures">Services Oriented Architectures</a><ul>
<li><a href="#where-have-we-come-from---eniac-1946">Where have we come from - ENIAC (1946)</a></li>
<li><a href="#where-have-we-come-from---early-client-server-computing-1960s">Where have we come from - Early Client-Server Computing (1960s)</a></li>
<li><a href="#where-have-we-come-from---personal-computers-1970s">Where have we come from - Personal Computers (1970s)</a></li>
<li><a href="#now---network-computing">Now - Network computing</a></li>
<li><a href="#network-computing-timeline">Network Computing Timeline</a></li>
<li><a href="#in-a-phrase">In a Phrase …</a></li>
<li><a href="#so---we-need-to-answer-the-following-questions">So - We Need to Answer the Following Questions</a></li>
<li><a href="#the-big-picture---services-oriented-architectures">The Big Picture - Services Oriented Architectures</a></li>
</ul></li>
<li><a href="#the-pieces---components">The Pieces - Components</a><ul>
<li><a href="#key-components---data">Key Components - Data</a></li>
<li><a href="#key-components---data-1">Key Components - Data</a></li>
<li><a href="#key-components---processing-services">Key Components - Processing Services</a></li>
<li><a href="#key-components---clients">Key Components - Clients</a></li>
</ul></li>
<li><a href="#the-glue---interoperability-standards-service-interfaces">The Glue - Interoperability Standards / Service Interfaces</a></li>
<li><a href="#open-geospatial-consortium-interoperability-standards">Open Geospatial Consortium Interoperability Standards</a><ul>
<li><a href="#open-geospatial-consortium-ogc-standards">Open Geospatial Consortium (OGC) Standards</a></li>
<li><a href="#comparison-of-ogc-service-models">Comparison of OGC Service Models</a></li>
<li><a href="#ogc-web-map-services-wms">OGC Web Map Services (WMS)</a></li>
<li><a href="#ogc-web-feature-services-wms-characteristics">OGC Web Feature Services (WMS) Characteristics</a></li>
<li><a href="#ogc-web-feature-services-wfs-characteristics">OGC Web Feature Services (WFS) Characteristics</a></li>
<li><a href="#ogc-web-coverage-services-wcs-characteristics">OGC Web Coverage Services (WCS) Characteristics</a></li>
<li><a href="#ogc-geography-markup-language-gml">OGC Geography Markup Language (GML)</a></li>
<li><a href="#ogc-kml">OGC KML</a></li>
<li><a href="#implementation-of-the-ogc-standards">Implementation of the OGC Standards</a></li>
<li><a href="#ogc-summary">OGC Summary</a></li>
<li><a href="#ogc-summary-1">OGC Summary</a></li>
</ul></li>
</ul></li>
<li><a href="#week-6---module-4a---interoperability-standards.-wms-kml-and-xml">Week 6 - Module 4a - Interoperability Standards. WMS, KML and XML</a><ul>
<li><a href="#overview-4">Overview</a></li>
<li><a href="#extensible-markup-language---xml">Extensible Markup Language - XML</a><ul>
<li><a href="#xml-background">XML Background</a></li>
<li><a href="#xml-design-goals">XML Design Goals</a></li>
<li><a href="#xml-structure---well-formed-valid">XML Structure - Well Formed / Valid</a></li>
<li><a href="#simple-xml-document">Simple XML Document</a></li>
<li><a href="#xml-prolog">XML Prolog</a></li>
<li><a href="#xml-elements">XML Elements</a></li>
<li><a href="#xml-root-element">XML Root Element</a></li>
<li><a href="#xml-content-elements">XML Content Elements</a></li>
<li><a href="#xml-attributes">XML Attributes</a></li>
<li><a href="#xml-element-content">XML Element Content</a></li>
<li><a href="#valid-xml">Valid XML?</a></li>
<li><a href="#common-xml-constructs">Common XML Constructs</a></li>
</ul></li>
<li><a href="#kml">KML</a><ul>
<li><a href="#kml-background">KML Background</a></li>
<li><a href="#kml-capabilities">KML Capabilities</a></li>
<li><a href="#kml-content">KML Content</a></li>
<li><a href="#d-and-3d-kml-sample">2D and 3D KML Sample</a></li>
<li><a href="#high-level-kml-content-types">High-Level KML Content Types</a></li>
<li><a href="#kml-demonstration-and-references">KML Demonstration and References</a></li>
</ul></li>
<li><a href="#ogc-web-map-services---wms">OGC Web map Services - WMS</a></li>
<li><a href="#wms---overview">WMS - Overview</a><ul>
<li><a href="#wms-getcapabilities-request">WMS <em>GetCapabilities</em> Request</a></li>
<li><a href="#wms-getmap-request-core">WMS <em>GetMap</em> Request (Core)</a></li>
<li><a href="#wms-getfeatureinfo-request">WMS GetFeatureInfo Request</a></li>
<li><a href="#wms-getcapabilities">WMS GetCapabilities</a></li>
<li><a href="#wms-getmap">WMS GetMap</a></li>
<li><a href="#integraton-of-wms-and-kml">Integraton of WMS and KML</a></li>
<li><a href="#sample-wms-kml-integration">Sample WMS-KML Integration</a></li>
</ul></li>
</ul></li>
<li><a href="#week-7---module-4a---interoperability-standards.-wfs-wcs">Week 7 - Module 4a - Interoperability Standards. WFS & WCS</a><ul>
<li><a href="#overview-5">Overview</a></li>
<li><a href="#ogc-web-feature-service-wfs">OGC Web Feature Service (WFS)</a><ul>
<li><a href="#background">Background</a></li>
<li><a href="#wfs-requestsoperations">WFS Requests/Operations</a></li>
<li><a href="#wfs-conformance-levels">WFS Conformance Levels</a></li>
<li><a href="#request-composition">Request Composition</a></li>
<li><a href="#kvp-for-base-wfs-requests">KVP for Base WFS Requests</a></li>
<li><a href="#sample-getcapabilities-requests">Sample GetCapabilities Requests</a></li>
<li><a href="#kvp-for-describefeaturetype-request">KVP for DescribeFeatureType Request</a></li>
<li><a href="#sample-describefeaturetype-requests">Sample DescribeFeatureType Requests</a></li>
<li><a href="#kvp-for-getfeature-request">KVP for GetFeature Request</a></li>
<li><a href="#kvp-for-getfeature-request---presentation-parameters">KVP for GetFeature Request - Presentation Parameters</a></li>
<li><a href="#kvp-for-getfeature-request---resolve-parameters">KVP for GetFeature Request - Resolve Parameters</a></li>
<li><a href="#kvp-for-getfeature-request---ad-hoc-query-parameters-figure">KVP for GetFeature Request - Ad-hoc Query Parameters (Figure )</a></li>
<li><a href="#kvp-for-getfeature-request---stored-query-parameters-figure">KVP for GetFeature Request - Stored Query Parameters (Figure )</a></li>
<li><a href="#sample-getfeature-requests">Sample GetFeature Requests</a></li>
</ul></li>
<li><a href="#ogc-web-coverage-services">OGC Web Coverage Services</a><ul>
<li><a href="#background-1">Background</a></li>
<li><a href="#wcs-requestsoperations">WCS Requests/Operations</a></li>
<li><a href="#request-composition-1">Request Composition</a></li>
<li><a href="#kvp-for-base-wcs-requests">KVP for Base WCS Requests</a></li>
<li><a href="#sample-wcs-getcapabilities-requests">Sample WCS <code>GetCapabilities</code> requests</a></li>
<li><a href="#kvp-for-describecoverage-request">KVP for DescribeCoverage Request</a></li>
<li><a href="#sample-describecoverage-request">Sample DescribeCoverage Request</a></li>
<li><a href="#kvp-for-getcoverage-request">KVP for GetCoverage Request</a></li>
<li><a href="#subset-definition-for-getcoverage-request">Subset Definition for GetCoverage Request</a></li>
<li><a href="#sample-getcoverage-request">Sample GetCoverage Request</a></li>
</ul></li>
</ul></li>
<li><a href="#week-10---module-2b---openlayers-4-javascript-framework">Week 10 - Module 2b - OpenLayers 4 Javascript Framework</a><ul>
<li><a href="#overview-6">Overview</a></li>
<li><a href="#openlayers-capabilities">OpenLayers Capabilities</a></li>
<li><a href="#distinguishing-characteristics-between-openlayers-and-google-maps">Distinguishing Characteristics Between OpenLayers and Google Maps</a></li>
<li><a href="#resources">Resources</a></li>
<li><a href="#demonstrations-and-examples">Demonstrations and Examples</a></li>
<li><a href="#demonstration-and-examples---online-resources">Demonstration and Examples - Online Resources</a></li>
<li><a href="#next-week---custom-features-and-wms-layers">Next Week - Custom Features and WMS Layers</a></li>
</ul></li>
<li><a href="#week-11---module-2b---openlayers-javascript-framework">Week 11 - Module 2b - OpenLayers Javascript Framework</a><ul>
<li><a href="#overview-7">Overview</a></li>
<li><a href="#map-object-options">Map Object Options</a></li>
<li><a href="#layer-object-options">Layer Object Options</a></li>
<li><a href="#additional-map-and-layer-object-functions-events">Additional Map and Layer Object Functions & Events</a></li>
<li><a href="#wms-layer-configuration">WMS Layer Configuration</a></li>
<li><a href="#vector-layer-configuration">Vector Layer Configuration</a></li>
</ul></li>
<li><a href="#week-12---module-4b---interoperability-standards---desktop-gis-integration">Week 12 - Module 4b - Interoperability Standards - Desktop GIS Integration</a><ul>
<li><a href="#overview-8">Overview</a></li>
<li><a href="#common-model">Common Model</a></li>
<li><a href="#full-getcapabilities-request">Full GetCapabilities Request</a></li>
<li><a href="#base-url-for-getcapabilities">Base URL for GetCapabilities</a></li>
<li><a href="#quantum-gis-qgis">Quantum GIS (QGIS)</a></li>
<li><a href="#qgis---adding-services-and-layers---start">QGIS - Adding Services and Layers - start</a></li>
<li><a href="#qgis---adding-services-and-layers---adding-a-service">QGIS - Adding Services and Layers - adding a service</a></li>
<li><a href="#qgis---adding-services-and-layers---adding-connection-information">QGIS - Adding Services and Layers - adding connection information</a></li>
<li><a href="#qgis---adding-services-and-layers---connecting-to-and-adding-layers-from-the-service">QGIS - Adding Services and Layers - connecting to and adding layers from the service</a></li>
<li><a href="#qgis---adding-services-and-layers---the-final-added-layer">QGIS - Adding Services and Layers - the final added layer</a></li>
<li><a href="#qgis-demonstration-with-wms-wfs-and-wcs-services">QGIS Demonstration with WMS, WFS and WCS Services</a></li>
<li><a href="#arcgis">ArcGIS</a></li>
<li><a href="#arcgis-wms-and-wcs-configuration">ArcGIS WMS and WCS Configuration</a></li>
<li><a href="#arcgis-wms-and-wcs-configuration-resources">ArcGIS WMS and WCS Configuration Resources</a></li>
<li><a href="#arcgis-wfs-configuration">ArcGIS WFS Configuration</a></li>
<li><a href="#arcgis-wfs-configuration-resources">ArcGIS WFS Configuration Resources</a></li>
<li><a href="#conclusions">Conclusions</a></li>
</ul></li>
<li><a href="#week-13---module-5---platforms-and-geoserver-introduction">Week 13 - Module 5 - Platforms and GeoServer Introduction</a><ul>
<li><a href="#soa-review">SOA Review</a></li>
<li><a href="#server-platform">Server Platform</a></li>
<li><a href="#online-mapping-server-applications">Online Mapping Server Applications</a></li>
<li><a href="#what-is-geoserver">What is GeoServer</a></li>
<li><a href="#working-with-geoserver">Working with GeoServer</a></li>
<li><a href="#what-is-happening-behind-the-scenes">What is Happening Behind the Scenes</a></li>
<li><a href="#setup-and-configuration">Setup and Configuration</a></li>
<li><a href="#server-configuration-options">Server Configuration Options</a></li>
<li><a href="#wxs-service-configuration-options">WxS Service Configuration Options</a></li>
<li><a href="#data-component-configuration-options">Data Component Configuration Options</a></li>
<li><a href="#data-integration-process">Data Integration Process</a></li>
<li><a href="#security-settings">Security Settings</a></li>
<li><a href="#demonstration-of-geoserver-interface">Demonstration of GeoServer Interface</a></li>
</ul></li>
<li><a href="#week-14---module-5---ogc-services-and-styling-in-geoserver">Week 14 - Module 5 - OGC Services and Styling in GeoServer</a><ul>
<li><a href="#overview-9">Overview</a></li>
<li><a href="#ogc-styled-layer-descriptor-sld">OGC Styled Layer Descriptor (SLD)</a><ul>
<li><a href="#ogc-styled-layer-descriptor-sld-1">OGC Styled Layer Descriptor (SLD)</a></li>
<li><a href="#definitionOfStyles_01">Definition of Styles</a></li>
<li><a href="#definitionOfStyles_03">Definition of Styles - Header Content</a></li>
<li><a href="#definitionOfStyles_04">Definition of Styles - Sample SLD File</a></li>
<li><a href="#simple-geoserver-point-style">Simple GeoServer Point Style</a></li>
<li><a href="#simple-geoserver-line-style">Simple GeoServer Line Style</a></li>
<li><a href="#simple-geoserver-polygon-style">Simple GeoServer Polygon Style</a></li>
<li><a href="#simple-geoserver-raster-style">Simple GeoServer Raster Style</a></li>
<li><a href="#pointsymbolizer">PointSymbolizer</a></li>
<li><a href="#linesybolizer">LineSybolizer</a></li>
<li><a href="#polygonsymbolizer">PolygonSymbolizer</a></li>
<li><a href="#raster-symbolizer">Raster Symbolizer</a></li>
</ul></li>
<li><a href="#filters">Filters</a><ul>
<li><a href="#SLDrulesVectorSymbolization_01">SLD Filter Rules and Vector Symbolization</a></li>
<li><a href="#attributeFilterExample_01">Attribute Filter Example</a></li>
<li><a href="#attributeFilterWscaleFactor_01">Attribute Filter with Scale Factor</a></li>
<li><a href="#demonstrations">Demonstrations</a></li>
</ul></li>
</ul></li>
<li><a href="#week-15---module-5---ogc-services-and-styling-in-geoserver">Week 15 - Module 5 - OGC Services and Styling in GeoServer</a><ul>
<li><a href="#overview-10">Overview</a></li>
<li><a href="#raster-symbolizer---review">Raster Symbolizer - Review</a></li>
<li><a href="#sample-raster-sld-for-color-map-examples">Sample Raster SLD for Color Map Examples</a></li>
<li><a href="#colormap-types">ColorMap Types</a></li>
<li><a href="#extend-or-not-to-extend">Extend or Not To Extend?</a></li>
<li><a href="#opacity">Opacity</a></li>
<li><a href="#channel-selection">Channel Selection</a></li>
<li><a href="#contrast-enhancement">Contrast Enhancement</a></li>
<li><a href="#sample-contrast-enhancement-sld-for-examples">Sample Contrast Enhancement SLD for Examples</a></li>
<li><a href="#geoserver-demoqa">GeoServer Demo/Q&A</a></li>
</ul></li>
<li><a href="#epilogue---geography-485l585l-closing-comments-and-next-steps">Epilogue - Geography 485L/585L Closing Comments and Next Steps</a><ul>
<li><a href="#what-weve-done">What We’ve Done …</a></li>
<li><a href="#where-do-you-go-from-here">Where Do You Go From Here?</a></li>
</ul></li>
</ul>
</nav>
<!---------------------------------------------------------------------------->
<!-- Week 01 ----------------------------------------------------------------->
<!-- Lecture 01 a 01 --------------------------------------------------------->
<!-- Introduction and Outline ------------------------------------------------>
<!---------------------------------------------------------------------------->
<h1 id="week-1---module-1---introduction-and-outline">Week 1 - Module 1 - Introduction and Outline</h1>
<h3 id="overview" class="module01">Overview</h3>
<ul>
<li>Introductions</li>
<li>Review of the Syllabus</li>
<li>Topics to be Covered</li>
<li>Basics/Definitions</li>
</ul>
<h3 id="introductions" class="module01">Introductions</h3>
<ul>
<li><p>Who am I?</p></li>
<li><p>Who are you?</p></li>
<li><p>What brought you here?</p></li>
</ul>
<h2 id="syllabus-review-link" class="module01">Syllabus Review (<a href="https://karlbenedict.github.io/GEOG485-585/syllabus.pdf">link</a>)</h2>
<h3 id="class-topics" class="module01">Class Topics</h3>
<ul>
<li><p>Internet Mapping Clients: Basic HTML, Javascript, CSS; Google Maps API; OpenLayers javascript library</p></li>
<li><p>Geospatial Services Oriented Architectures (SOA)</p></li>
<li><p>Open Standards: Open Geospatial Consortium (OGC - <a href="http://www.opengeospatial.org/standards/wms">WMS</a>, <a href="http://www.opengeospatial.org/standards/wfs">WFS</a>, <a href="http://www.opengeospatial.org/standards/wcs">WCS</a>, <a href="http://www.opengeospatial.org/standards/kml">KML</a>); Extensible Markup Language (<a href="http://www.w3.org/XML/">XML</a>)</p></li>
<li><p>Desktop client use of Open Standards</p></li>
<li><p>Data sharing/publication using Open Standards</p></li>
</ul>
<h2 id="basics" class="module01">Basics</h2>
<h3 id="outline" class="module01">Outline</h3>
<ul>
<li><p>What is Internet Mapping?</p></li>
<li><p>Definitions</p></li>
<li><p>Tools</p></li>
</ul>
<h3 id="what-is-internet-mapping" class="module01">What is Internet Mapping</h3>
<dl>
<dt><em>Extended Desktop Mapping</em></dt>
<dd><p>Use of open standards based remote data and map services in desktop applications</p>
</dd>
<dt><em>Geospatial Data Sharing</em></dt>
<dd><p>Establishing open standards based services to share geospatial data and mapping capabilities over the Internet</p>
</dd>
<dt><em>Web-client Mapping</em></dt>
<dd><p>The delivery of mapping and geospatial data tools through web browsers, again based upon open standards</p>
</dd>
</dl>
<h3 id="definitions" class="module01">Definitions</h3>
<dl>
<dt>Internet</dt>
<dd><p>The global computer network of computers that typically connect with each other over TCP/IP</p>
</dd>
<dt>World Wide Web</dt>
<dd><p>The subset of applications that are run over the Internet, typically using the HTTP protocol in combination with data (HTML, XML, XHTML), presentation (CSS), and behavior (JavaScript) components</p>
</dd>
<dt>Mapping</dt>
<dd><p>The generation of cartographic products that include map images (pictures of geospatial data) and other elements (e.g. legends, tools, scale information, north-arrow)</p>
</dd>
<dt>Analysis</dt>
<dd><p>The development of models (statistical and otherwise) that enable the exploration of geospatial data and testing of hypotheses using those data</p>
</dd>
<dt>Open Standards</dt>
<dd><p>While the definition varies from one organization to the next, Open Standards are often characterized by the following:</p>
</dd>
</dl>
<ul>
<li>Developed through a public process by a national or international standards group</li>
<li>May be implemented royalty-free</li>
</ul>
<dl>
<dt>Interoperability</dt>
<dd><p>Ability of systems to share data and information with each other</p>
</dd>
<dt>COTS</dt>
<dd><p>Commercial Off-the-Shelf Software. Applications that are “purchased” from vendors, often with license terms that restrict the use the software to the specific platform for which it is licensed. Often comes with implicit or explicit technical support</p>
</dd>
<dt>Open Source</dt>
<dd><p>Software licensed under terms that are consistent with the Open Source definition, which includes access to source code, and freedom to modify and redistribute</p>
</dd>
<dt>Data</dt>
<dd><p>Actual values associated with geographic locations. For example - numeric elevation values associated with locations within a Digital Elevation Model.</p>
</dd>
<dt>Metadata</dt>
<dd><p>Data about a particular data product or service. Metadata provide critical documentation that supports the discovery and use of data products and data and mapping services</p>
</dd>
</dl>
<h2 id="tools" class="module01">Tools</h2>
<h3 id="computer-hardware-requirements" class="module01">Computer Hardware Requirements</h3>
<ul>
<li>At least 2 GB RAM</li>
<li>At least 20 GB of available disk space</li>
<li>Internet Connection (broadband [>728 Kb/sec] recommended)</li>
</ul>
<h3 id="software-requirements" class="module01">Software Requirements</h3>
<ul>
<li>Supported Operating System</li>
<li>Geographic Information System (GIS)</li>
<li>Text Editor</li>
<li>Secure File Transfer Protocol Client</li>
<li>Secure Shell (SSH) Client</li>
<li>Web Browser (at least one of the following)</li>
<li>A desktop Git/GitHub client for your operating system of choice</li>
</ul>
<!---------------------------------------------------------------------------->
<!-- Week 02 ----------------------------------------------------------------->
<!-- Lecture 02 a 01 --------------------------------------------------------->
<!-- Web-based Mapping Clients------------------------------------------------>
<!-- Introduction to HTML, CSS and Javascript--------------------------------->
<!---------------------------------------------------------------------------->
<h1 id="week-2---module-2a---web-based-mapping-clients.-html-css-javascript">Week 2 - Module 2a - Web-based Mapping Clients. HTML, CSS & Javascript</h1>
<h3 id="overview-1" class="module02a01">Overview</h3>
<ul>
<li>Web Development</li>
<li>Parts of a web page</li>
<li>Web Site Components
<ul>
<li>Structure (X/HTML)</li>
<li>Presentation (CSS)</li>
<li>Behavior (Javascript)</li>
</ul></li>
<li>Simple Web Pages</li>
<li>More Complete Web Page Example</li>
</ul>
<h3 id="web-development" class="module02a01">Web Development</h3>
<ul>
<li>Requirements
<ul>
<li>Web Server</li>
<li>File location that the web server accesses for requested content</li>
<li>Files must be readable by all users</li>
</ul></li>
<li>General Process
<ul>
<li>Create basic content in HTML or XHTML (structure)</li>
<li>Change appearance of content through the definitions of styles using CSS (presentation)</li>
<li>Add dynamic capabilities to content through Javascript (behavior)</li>
<li>REPEAT over and over and over and over again</li>
</ul></li>
</ul>
<h3 id="parts-of-a-web-page" class="module02a01">Parts of a Web Page</h3>
<div class="sourceCode" id="cb1"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb1-1" data-line-number="1"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb1-2" data-line-number="2"> <span class="co"><!-- The HTML block is the container for all of your page content --></span></a>
<a class="sourceLine" id="cb1-3" data-line-number="3"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb1-4" data-line-number="4"> <span class="co"><!-- The head is where you include pointers to external resources </span></a>
<a class="sourceLine" id="cb1-5" data-line-number="5"><span class="co"> (i.e. style sheets and javascript files), blocks of Javascript code</span></a>
<a class="sourceLine" id="cb1-6" data-line-number="6"><span class="co"> , styles, etc. --></span></a>
<a class="sourceLine" id="cb1-7" data-line-number="7"> <span class="kw"><title></span>The page title also goes in here<span class="kw"></title></span></a>
<a class="sourceLine" id="cb1-8" data-line-number="8"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb1-9" data-line-number="9"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb1-10" data-line-number="10"> <span class="co"><!-- The body is where you put all of the content for the page </span></a>
<a class="sourceLine" id="cb1-11" data-line-number="11"><span class="co"> (i.e. the material that will be displayed in the web browser) --></span></a>
<a class="sourceLine" id="cb1-12" data-line-number="12"> <span class="kw"><h1></span>Headers<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb1-13" data-line-number="13"> <span class="kw"><div></span>Generic blocks of content<span class="kw"></div></span></a>
<a class="sourceLine" id="cb1-14" data-line-number="14"> <span class="kw"><p></span>Paragraphs<span class="kw"></p></span></a>
<a class="sourceLine" id="cb1-15" data-line-number="15"> <span class="kw"><table></span>Tables<span class="kw"></table></span></a>
<a class="sourceLine" id="cb1-16" data-line-number="16"> <span class="kw"><img</span> <span class="er">...</span><span class="kw">></span>Images<span class="kw"></img></span></a>
<a class="sourceLine" id="cb1-17" data-line-number="17"> <span class="kw"><form</span> <span class="er">...</span><span class="kw">></span>Forms<span class="kw"></form></span></a>
<a class="sourceLine" id="cb1-18" data-line-number="18"> <span class="kw"><ul></span>Unordered Lists<span class="kw"></ul></span></a>
<a class="sourceLine" id="cb1-19" data-line-number="19"> <span class="kw"><ol></span>Ordered Lists<span class="kw"></ol></span></a>
<a class="sourceLine" id="cb1-20" data-line-number="20"> <span class="kw"><li></span>List Items<span class="kw"></li></span></a>
<a class="sourceLine" id="cb1-21" data-line-number="21"> </a>
<a class="sourceLine" id="cb1-22" data-line-number="22"> <span class="co"><!-- Javascript can go here as well --></span></a>
<a class="sourceLine" id="cb1-23" data-line-number="23"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb1-24" data-line-number="24"><span class="kw"></html></span></a></code></pre></div>
<p><a href="https://karlbenedict.github.io/GEOG485-585/sample-files/example02_01_01.html">Link to example</a></p>
<h3 id="web-site-components---structure" class="module02a01">Web Site Components - Structure</h3>
<p>Content is defined in terms of the structural elements available in HTML/XHTML</p>
<ul>
<li>Sample HTML/XHTML Tags
<ul>
<li>Paragraphs (i.e. blocks of text) are contained within <code><p>...</p></code> tags</li>
<li>Headings (i.e. section headings, sub-headings) are contained within numerically defined header tags: <code><h1>...</h1>, <h2>...</h2>, <h3>...</h3></code>, etc.</li>
<li>Tabular data are within <code><table>...</table></code> tags</li>
<li>List are specified within <code><ol>...</ol></code> or <code><ul>...</ul></code> tags, depending upon whether the list is ordered (numbered) or unordered (e.g. bulleted)</li>
<li>User input elements are put within <code><form>...</form></code> tags</li>
<li>Blocks of content (i.e. sections or divisions) are defined within <code><div>...</div></code> tags</li>
</ul></li>
<li>Structure is translated into the Document Object Model (DOM) for later use by CSS and Javascript</li>
</ul>
<h3 id="web-site-components---presentation" class="module02a01">Web Site Components - Presentation</h3>
<p>Modifications to default rendering of HTML/XHTML elements are made through styles defined in CSS</p>
<ul>
<li>Styles may be
<ul>
<li>defined in an external file that is referenced within the <code><head></code> block (the preferred method when doing “real” web development)</li>
<li>directly defined within the <code><head></code> block of a web page</li>
<li>directly embedded in the elements to which they apply (generally not a “Good Thing”)</li>
</ul></li>
<li>When not embedded within an element, a style definition consists of
<ul>
<li>A selector</li>
<li>The style definition, enclosed in “curly-brackets”, separated by “semi-colons”</li>
<li>For example: <code>h1 {color:red; font-size:18px;}</code></li>
</ul></li>
</ul>
<h3 id="css-selectors" class="module02a01">CSS Selectors</h3>
<p>Selectors may be based on several criteria</p>
<ul>
<li>Element name: <code>h1</code>, <code>p</code>, <code>table</code>, <code>ul</code>, etc.
<ul>
<li>Element: <code><h1>A top level heading</h1></code></li>
<li>Selector: <code>h1 {color:red; font-size:18px}</code></li>
</ul></li>
<li>Element ID: a unique name assigned to HTML/XHTML elements within the structure of the document
<ul>
<li>Element: <code><p id=”para01”>Some text goes here</p></code></li>
<li>Selector: <code>#para01 {color:blue; font-size:12px}</code></li>
</ul></li>
<li>Class ID: a name assigned to multiple elements which may be modified through reference to their class
<ul>
<li>Element: <code><p class=”instructions”>Here are some instructions</p></code></li>
<li>Another Element: <code><p class=”instructions”>Here are some more instructions</p></code></li>
<li>Selector: <code>.instructions {color:red; font-size:12px; text-decoration:blink}</code></li>
</ul></li>
<li>Selectors may be combined in a variety of ways</li>
</ul>
<h3 id="web-site-components---behavior" class="module02a01">Web Site Components - Behavior</h3>
<p>The most interoperable language for adding dynamic behavior to web sites is <em>Javascript</em> - supported by most browsers on most operating systems</p>
<ul>
<li>A full-fledged programming language
<ul>
<li>A non-trivial undertaking to become proficient in</li>
<li>Experience in other programming languages can contribute to learning Javascript</li>
</ul></li>
<li>Defines actions that may be taken on/by DOM elements</li>
<li>Allows for modification of existing DOM elements, creation of new DOM elements after the page has finished loading from the server, retrieval of new content after page loads
<ul>
<li>An interactive web page that may behave like a local desktop application</li>
</ul></li>
</ul>
<h3 id="reference-links" class="module02a01">Reference Links</h3>
<ul>
<li>w3schools.com
<ul>
<li><a href="http://www.w3schools.com/html/html5_intro.asp">HTML 5.0 Introduction</a></li>
<li><a href="http://www.w3schools.com/tags/default.asp">HTML 4.0 / XHTML 1.0 Tag Reference</a></li>
<li><a href="http://www.w3schools.com/css/default.asp">Cascading Style Sheet (CSS) selectors and elements</a></li>
<li><a href="http://www.w3schools.com/js/default.asp">Javascript reference</a></li>
</ul></li>
<li>World Wide Web Consortium (W3C)
<ul>
<li><a href="http://www.w3.org/standards/webdesign/htmlcss">HTML and CSS Background</a></li>
<li><a href="http://www.w3.org/2002/03/tutorials.html#webdesign_htmlcss">HTML and CSS Tutorial Links Page</a></li>
<li><a href="http://validator.w3.org/">Validators Page</a></li>
</ul></li>
<li>Webmonkey.com
<ul>
<li><a href="https://www.wired.com/2010/02/html_cheatsheet/">HTML Cheat Sheet</a></li>
<li><a href="https://www.wired.com/2010/02/css-guide/">CSS Guide</a></li>
</ul></li>
</ul>
<h3 id="simple-web-page" class="module02a01">Simple Web Page</h3>
<div class="sourceCode" id="cb2"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb2-1" data-line-number="1"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb2-2" data-line-number="2"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb2-3" data-line-number="3"> <span class="kw"><meta</span><span class="ot"> http-equiv=</span><span class="st">"Content-Type"</span><span class="ot"> content=</span><span class="st">"text/html;charset=utf-8"</span> <span class="kw">/></span></a>
<a class="sourceLine" id="cb2-4" data-line-number="4"> <span class="kw"><title></span>This is a simple web page<span class="kw"></title></span></a>
<a class="sourceLine" id="cb2-5" data-line-number="5"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb2-6" data-line-number="6"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb2-7" data-line-number="7"> <span class="kw"><h1></span>They don't get any simpler than this!<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb2-8" data-line-number="8"> <span class="kw"><p></span>OK, not much simpler than this.<span class="kw"></p></span></a>
<a class="sourceLine" id="cb2-9" data-line-number="9"> <span class="kw"><p></span>Hello World?<span class="kw"></p></span></a>
<a class="sourceLine" id="cb2-10" data-line-number="10"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb2-11" data-line-number="11"><span class="kw"></html></span></a></code></pre></div>
<p><a href="https://karlbenedict.github.io/GEOG485-585/sample-files/example02_01_02.html">link to example</a></p>
<h3 id="simple-web-page-with-css">Simple Web Page with CSS</h3>
<div class="sourceCode" id="cb3"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb3-1" data-line-number="1"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb3-2" data-line-number="2"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb3-3" data-line-number="3"> <span class="kw"><meta</span><span class="ot"> http-equiv=</span><span class="st">"Content-Type"</span><span class="ot"> content=</span><span class="st">"text/html;charset=utf-8"</span> <span class="kw">/></span></a>
<a class="sourceLine" id="cb3-4" data-line-number="4"> <span class="kw"><title></span>This is a simple web page - with styling<span class="kw"></title></span></a>
<a class="sourceLine" id="cb3-5" data-line-number="5"> <span class="kw"><style</span><span class="ot"> type=</span><span class="st">"text/css"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb3-6" data-line-number="6"> h1 {<span class="kw">color</span>:<span class="dv">blue</span>; <span class="kw">font-size</span>:<span class="dv">large</span>}</a>
<a class="sourceLine" id="cb3-7" data-line-number="7"> p<span class="fu">.para</span> {<span class="kw">color</span>:<span class="dv">#777777</span>; <span class="kw">font-size</span>:<span class="dv">small</span>}</a>
<a class="sourceLine" id="cb3-8" data-line-number="8"> <span class="pp">#annoying</span> {<span class="kw">color</span>:<span class="dv">red</span>; <span class="kw">text-decoration</span>:<span class="dv">line-through</span>}</a>
<a class="sourceLine" id="cb3-9" data-line-number="9"> <span class="kw"></style></span></a>
<a class="sourceLine" id="cb3-10" data-line-number="10"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb3-11" data-line-number="11"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb3-12" data-line-number="12"> <span class="kw"><h1></span>They don't get any simpler than this!<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb3-13" data-line-number="13"> <span class="kw"><p</span><span class="ot"> class=</span><span class="st">"para"</span><span class="kw">></span>OK, not much simpler than this.<span class="kw"></p></span></a>
<a class="sourceLine" id="cb3-14" data-line-number="14"> <span class="kw"><p</span><span class="ot"> id=</span><span class="st">"annoying"</span><span class="ot"> class=</span><span class="st">"para"</span><span class="kw">></span>Hello World?<span class="kw"></p></span></a>
<a class="sourceLine" id="cb3-15" data-line-number="15"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb3-16" data-line-number="16"><span class="kw"></html></span></a></code></pre></div>
<p><a href="https://karlbenedict.github.io/GEOG485-585/sample-files/example02_01_03.html">link to example</a></p>
<h3 id="simple-web-page-with-javascript">Simple Web Page with Javascript</h3>
<div class="sourceCode" id="cb4"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb4-1" data-line-number="1"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb4-2" data-line-number="2"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb4-3" data-line-number="3"> <span class="kw"><meta</span><span class="ot"> http-equiv=</span><span class="st">"Content-Type"</span><span class="ot"> content=</span><span class="st">"text/html;charset=utf-8"</span> <span class="kw">/></span></a>
<a class="sourceLine" id="cb4-4" data-line-number="4"> <span class="kw"><title></span>This is a simple web page with Javascript<span class="kw"></title></span></a>
<a class="sourceLine" id="cb4-5" data-line-number="5"> <span class="kw"><script</span><span class="ot"> type=</span><span class="st">"text/javascript"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb4-6" data-line-number="6"> <span class="kw">function</span> <span class="at">genericAlert</span>() <span class="op">{</span></a>
<a class="sourceLine" id="cb4-7" data-line-number="7"> <span class="at">alert</span>(<span class="st">"You just did something ..."</span>)</a>
<a class="sourceLine" id="cb4-8" data-line-number="8"> <span class="va">document</span>.<span class="at">getElementById</span>(<span class="st">"clickMe"</span>).<span class="va">style</span>.<span class="at">color</span> <span class="op">=</span> <span class="st">"red"</span></a>
<a class="sourceLine" id="cb4-9" data-line-number="9"> <span class="op">}</span></a>
<a class="sourceLine" id="cb4-10" data-line-number="10"> <span class="kw"></script></span></a>
<a class="sourceLine" id="cb4-11" data-line-number="11"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb4-12" data-line-number="12"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb4-13" data-line-number="13"> <span class="kw"><h1></span>They don't get any simpler than this!<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb4-14" data-line-number="14"> <span class="kw"><p></span>OK, not much simpler than this.<span class="kw"></p></span></a>
<a class="sourceLine" id="cb4-15" data-line-number="15"> <span class="kw"><p></span>Hello World?<span class="kw"></p></span></a>
<a class="sourceLine" id="cb4-16" data-line-number="16"> <span class="kw"><p</span><span class="ot"> id=</span><span class="st">"clickMe"</span><span class="ot"> onclick=</span><span class="st">"genericAlert();"</span><span class="kw">></span>What happens when you click me?<span class="kw"></p></span></a>
<a class="sourceLine" id="cb4-17" data-line-number="17"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb4-18" data-line-number="18"><span class="kw"></html></span></a></code></pre></div>
<p><a href="https://karlbenedict.github.io/GEOG485-585/sample-files/example02_01_04.html">link to example</a></p>
<!---------------------------------------------------------------------------->
<!-- Week 03 ----------------------------------------------------------------->
<!-- Lecture 02 a 02 a ------------------------------------------------------->
<!-- Web-based Mapping Clients------------------------------------------------>
<!-- Google Maps API---------------------------------------------------------->
<!---------------------------------------------------------------------------->
<h1 id="week-3--module-2a---web-based-mapping-clients.-google-maps-api">Week 3- Module 2a - Web-based Mapping Clients. Google Maps API</h1>
<h3 id="outline-1" class="module02a02a">Outline</h3>
<ul>
<li><p>What is an API</p></li>
<li>The Google Maps API
<ul>
<li>Version</li>
<li>Reference Information</li>
<li>Key Components</li>
<li>Examples</li>
</ul></li>
</ul>
<h3 id="what-is-an-api" class="module02a02a">What is an API</h3>
<ul>
<li>API Stands for Application Programming Interface</li>
</ul>
<blockquote>
<p>An Application Programming Interface (API) is a particular set of rules and specifications that a software program can follow to access and make use of the services and resources provided by another particular software program that implements that API. It serves as an interface between different software programs and facilitates their interaction, similar to the way the user interface facilitates interaction between humans and computers. – From Wikipedia: <a href="http://en.wikipedia.org/wiki/Api" class="uri">http://en.wikipedia.org/wiki/Api</a></p>
</blockquote>
<ul>
<li>The Google Maps API provides an interface for interacting with Google’s mapping services from external web applications</li>
</ul>
<h3 id="google-maps-api-version" class="module02a02a">Google Maps API Version</h3>
<ul>
<li>The version of the Google Maps API used in this class is v3 of the Javascript API
<ul>
<li>Freely usable for free applications</li>
<li>Subject to Google’s Terms of Service</li>
<li>Google <a href="https://developers.google.com/maps/faq?hl=en#using-google-maps-apis">API key is now required</a></li>
</ul></li>
<li>Key capabilities in v3
<ul>
<li>Interactive maps based on Google’s mapping engine (contrast w. static maps API)</li>
<li>Optimized for desktop and mobile platforms and applications</li>
</ul></li>
</ul>
<h3 id="reference-information" class="module02a02a">Reference Information</h3>
<dl>
<dt>Google Maps API Family</dt>
<dd><a href="https://developers.google.com/maps/?csw=1">http://code.google.com/apis/maps/</a>
</dd>
<dt>Javascript API Home Page</dt>
<dd><a href="https://developers.google.com/maps/documentation/javascript/?csw=1" class="uri">https://developers.google.com/maps/documentation/javascript/?csw=1</a>
</dd>
<dt>Javascript API v3 Tutorial Page</dt>
<dd><a href="https://developers.google.com/maps/documentation/javascript/tutorial?csw=1">http://code.google.com/apis/maps/documentation/javascript/tutorial.html</a>
</dd>
</dl>
<h3 id="key-components" class="module02a02a">Key Components</h3>
<ul>
<li>Map <a href="https://developers.google.com/maps/documentation/javascript/reference?csw=1#MapOptions">object options</a></li>
</ul>
<dl>
<dt>Types (required)</dt>
<dd>ROADMAP
</dd>
<dd>SATELLITE
</dd>
<dd>HYBRID
</dd>
<dd>TERRAIN
</dd>
<dt>Latitude and Longitude (required)</dt>
<dd>specification of where the map should initially be centered
</dd>
<dt>Zoom Level (required)</dt>
<dd>0=global, higher values increasingly local. Limited by map type
</dd>
</dl>
<h3 id="controls" class="module02a02a">Controls</h3>
<ul>
<li>Available Controls (enabled through map options) <a href="https://developers.google.com/maps/documentation/javascript/controls?csw=1#DefaultUI">default controls</a>
<ul>
<li>Zoom Control</li>
<li>Scale Control</li>
<li>MapType Control</li>
<li>Street View Control</li>
<li>Rotate (for maps that contain 45-degree imagery)</li>
<li>Fullscreen Control</li>
</ul></li>
<li>Different control styles may be defined</li>
<li>Controls may be positioned <a href="https://developers.google.com/maps/documentation/javascript/controls?csw=1#ControlPositioning">positioning options</a></li>
<li>Custom controls may be defined and attached to fixed location in the map</li>
</ul>
<h3 id="overlays" class="module02a02a">Overlays</h3>
<p>Overlay Types <a href="https://developers.google.com/maps/documentation/javascript/overlays?csw=1">documentation</a></p>
<dl>
<dt>Marker</dt>
<dd>points depicted by specified or defined icons at locations within the map (<a href="https://developers.google.com/maps/documentation/javascript/markers">reference</a>)
</dd>
<dt>Polyline</dt>
<dd>linear features defined by multiple points with a defined style for the line (<a href="https://developers.google.com/maps/documentation/javascript/shapes">reference</a>)
</dd>
<dt>Polygon</dt>
<dd>closed features defined by multiple points. Supports multi-polygons, and donuts. Line and fill styles may be specified. (<a href="https://developers.google.com/maps/documentation/javascript/shapes">reference</a>)
</dd>
<dt>(Ground) Overlay Maps</dt>
<dd>Image-based map layers that replace or overlay Google layers - registered to the map coordinates (<a href="https://developers.google.com/maps/documentation/javascript/groundoverlays">reference</a>)
</dd>
<dt>Info Windows</dt>
<dd>floating content windows for displaying content defined as HTML, a DOM element, or text string (<a href="https://developers.google.com/maps/documentation/javascript/infowindows">reference</a>)
</dd>
<dt>Layers</dt>
<dd>Grouped display content assigned to a specific layer type: Data (including GeoJSON), KmlLayer (& GeoRSS), Heatmap, FusionTablesLayer, TrafficLayer, TransitLayer, BicyclingLayer (<a href="https://developers.google.com/maps/documentation/javascript/layers">reference</a>)
</dd>
<dt>Custom Overlays</dt>
<dd>definition of programmatically controlled layers (<a href="https://developers.google.com/maps/documentation/javascript/customoverlays">reference</a>)
</dd>
</dl>
<h3 id="services" class="module02a02a">Services</h3>
<ul>
<li>Geocoding Service
<ul>
<li>Forward and reverse geocoding:
<ul>
<li>address to LatLon</li>
<li>LatLon to Nearest Address</li>
</ul></li>
<li>May be biased to current viewport, region</li>
</ul></li>
<li>Directions
<ul>
<li>Based upon an origin, destination, and a variety of additional options</li>
<li>Available directions and rendered route</li>
</ul></li>
<li>Distance Matrix
<ul>
<li>Travel distance and duration given a specific mode of travel</li>
</ul></li>
<li>Elevation
<ul>
<li>Delivery of elevation data for locations or paths</li>
</ul></li>
<li>Streetview
<ul>
<li>Integration of Google Streetview within a DOM element</li>
</ul></li>
<li>Maximum Zoom
<ul>
<li>Provides information about the maximum available zoom level</li>
</ul></li>
</ul>
<h3 id="events" class="module02a02a">Events</h3>
<ul>
<li>Events provide the ability to attach custom behaviors to events in the interface. For example:
<ul>
<li>Changing items in the interface as the user zooms in on a map</li>
<li>Displaying additional information outside the map when the user clicks a location in the map</li>
<li>Synchronizing the behavior of multiple maps as the user interacts with one map</li>
</ul></li>
<li>Requires higher-level Javascript than we will cover in this course</li>
</ul>
<h3 id="examples" class="module02a02a">Examples</h3>
<h3 id="simple---roadmap" class="module02a02a">Simple - Roadmap</h3>
<p><img src="images/gmaps01.png" alt="gmaps01.html preview" /> </p>
<h3 id="simple---roadmap-code" class="module02a02a">Simple - Roadmap Code</h3>
<div class="codeTable">
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/gmaps01.html">gmaps01.html</a></p>
<div class="sourceCode" id="cb5"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb5-1" data-line-number="1"><span class="dt"><!DOCTYPE </span>html<span class="dt">></span></a>
<a class="sourceLine" id="cb5-2" data-line-number="2"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb5-3" data-line-number="3"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb5-4" data-line-number="4"> <span class="kw"><link</span><span class="ot"> rel=</span><span class="st">"stylesheet"</span><span class="ot"> type=</span><span class="st">"text/css"</span><span class="ot"> href=</span><span class="st">"css/mapPage.css"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb5-5" data-line-number="5"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb5-6" data-line-number="6"></a>
<a class="sourceLine" id="cb5-7" data-line-number="7"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb5-8" data-line-number="8"> <span class="kw"><h1></span>Sample Map<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb5-9" data-line-number="9"> <span class="kw"><div</span><span class="ot"> id=</span><span class="st">"map_canvas"</span><span class="kw">></div></span></a>
<a class="sourceLine" id="cb5-10" data-line-number="10"></a>
<a class="sourceLine" id="cb5-11" data-line-number="11"> <span class="co"><!-- Let's put our JavaScript down here </span><span class="er">-------------------------------------------</span><span class="co">--></span></a>
<a class="sourceLine" id="cb5-12" data-line-number="12"> <span class="co"><!-- Load the external JavaScript file with the map definition code --></span></a>
<a class="sourceLine" id="cb5-13" data-line-number="13"> <span class="kw"><script</span><span class="ot"> src=</span><span class="st">"js/mapPage_01.js"</span><span class="kw">></script></span></a>
<a class="sourceLine" id="cb5-14" data-line-number="14"> </a>
<a class="sourceLine" id="cb5-15" data-line-number="15"> <span class="co"><!-- Load the API in asynchronous mode and execute the initialize </span></a>
<a class="sourceLine" id="cb5-16" data-line-number="16"><span class="co"> function when done --></span></a>
<a class="sourceLine" id="cb5-17" data-line-number="17"> <span class="kw"><script</span><span class="ot"> async defer</span> </a>
<a class="sourceLine" id="cb5-18" data-line-number="18"><span class="ot"> src=</span><span class="st">"https://maps.googleapis.com/maps/api/js?callback=initialize</span><span class="er">&</span><span class="st">key=</span><span class="er"><</span><span class="st">mykey>"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb5-19" data-line-number="19"> <span class="kw"></script></span></a>
<a class="sourceLine" id="cb5-20" data-line-number="20"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb5-21" data-line-number="21"><span class="kw"></html></span></a></code></pre></div>
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/css/mapPage.css">mapPage.css</a></p>
<div class="sourceCode" id="cb6"><pre class="sourceCode numberSource css numberLines"><code class="sourceCode css"><a class="sourceLine" id="cb6-1" data-line-number="1"><span class="co">/* You must set the height of either the 'html' or 'body' elements for some </span></a>
<a class="sourceLine" id="cb6-2" data-line-number="2"><span class="co"> browsers to properly render the map with a hight taller than 0px */</span></a>
<a class="sourceLine" id="cb6-3" data-line-number="3">html { </a>
<a class="sourceLine" id="cb6-4" data-line-number="4"> <span class="kw">height</span>: <span class="dv">100%</span> }</a>
<a class="sourceLine" id="cb6-5" data-line-number="5"></a>
<a class="sourceLine" id="cb6-6" data-line-number="6">body { </a>
<a class="sourceLine" id="cb6-7" data-line-number="7"> <span class="kw">height</span>: <span class="dv">100%</span>; </a>
<a class="sourceLine" id="cb6-8" data-line-number="8"> <span class="kw">margin</span>: <span class="dv">0px</span>; </a>
<a class="sourceLine" id="cb6-9" data-line-number="9"> <span class="kw">padding</span>: <span class="dv">0px</span>; </a>
<a class="sourceLine" id="cb6-10" data-line-number="10"> <span class="kw">background-color</span>: <span class="dv">black</span>; </a>
<a class="sourceLine" id="cb6-11" data-line-number="11"> <span class="kw">color</span>: <span class="dv">#CCCCCC</span>;</a>
<a class="sourceLine" id="cb6-12" data-line-number="12"> <span class="kw">text-align</span>: <span class="dv">center</span>}</a>
<a class="sourceLine" id="cb6-13" data-line-number="13"> </a>
<a class="sourceLine" id="cb6-14" data-line-number="14"><span class="pp">#map_canvas</span> { </a>
<a class="sourceLine" id="cb6-15" data-line-number="15"> <span class="kw">width</span>:<span class="dv">90%</span>; </a>
<a class="sourceLine" id="cb6-16" data-line-number="16"> <span class="kw">height</span>:<span class="dv">80%</span>; </a>
<a class="sourceLine" id="cb6-17" data-line-number="17"> <span class="kw">margin-left</span>:<span class="dv">auto</span>; </a>
<a class="sourceLine" id="cb6-18" data-line-number="18"> <span class="kw">margin-right</span>: <span class="dv">auto</span> }</a>
<a class="sourceLine" id="cb6-19" data-line-number="19"> </a>
<a class="sourceLine" id="cb6-20" data-line-number="20"><span class="fu">.infoBox</span> { </a>
<a class="sourceLine" id="cb6-21" data-line-number="21"> <span class="kw">color</span>:<span class="dv">black</span> }</a></code></pre></div>
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/js/mapPage_01.js">mapPage_01.js</a></p>
<div class="sourceCode" id="cb7"><pre class="sourceCode numberSource js numberLines"><code class="sourceCode javascript"><a class="sourceLine" id="cb7-1" data-line-number="1"><span class="kw">function</span> <span class="at">initialize</span>() <span class="op">{</span></a>
<a class="sourceLine" id="cb7-2" data-line-number="2"> <span class="kw">var</span> classroom <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">LatLng</span>(<span class="fl">35.084280</span><span class="op">,-</span><span class="fl">106.624073</span>)</a>
<a class="sourceLine" id="cb7-3" data-line-number="3"> <span class="kw">var</span> mapOptions <span class="op">=</span> <span class="op">{</span></a>
<a class="sourceLine" id="cb7-4" data-line-number="4"> <span class="dt">zoom</span><span class="op">:</span> <span class="dv">8</span><span class="op">,</span></a>
<a class="sourceLine" id="cb7-5" data-line-number="5"> <span class="dt">center</span><span class="op">:</span> classroom<span class="op">,</span></a>
<a class="sourceLine" id="cb7-6" data-line-number="6"> <span class="dt">mapTypeId</span><span class="op">:</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="va">MapTypeId</span>.<span class="at">ROADMAP</span></a>
<a class="sourceLine" id="cb7-7" data-line-number="7"> <span class="op">};</span></a>
<a class="sourceLine" id="cb7-8" data-line-number="8"> <span class="kw">var</span> map <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">Map</span>(</a>
<a class="sourceLine" id="cb7-9" data-line-number="9"> <span class="va">document</span>.<span class="at">getElementById</span>(<span class="st">"map_canvas"</span>)<span class="op">,</span></a>
<a class="sourceLine" id="cb7-10" data-line-number="10"> mapOptions)<span class="op">;</span></a>
<a class="sourceLine" id="cb7-11" data-line-number="11"><span class="op">}</span></a>
<a class="sourceLine" id="cb7-12" data-line-number="12"></a></code></pre></div>
</div>
<h3 id="simple---satellite" class="module02a02a">Simple - Satellite</h3>
<p><img src="images/gmaps02.png" alt="gmaps02.html preview" /> </p>
<h3 id="simple---satellite-code" class="module02a02a">Simple - Satellite Code</h3>
<div class="codeTable">
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/gmaps02.html">gmaps02.html</a></p>
<div class="sourceCode" id="cb8"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb8-1" data-line-number="1"><span class="dt"><!DOCTYPE </span>html<span class="dt">></span></a>
<a class="sourceLine" id="cb8-2" data-line-number="2"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb8-3" data-line-number="3"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb8-4" data-line-number="4"> <span class="kw"><link</span><span class="ot"> rel=</span><span class="st">"stylesheet"</span><span class="ot"> type=</span><span class="st">"text/css"</span><span class="ot"> href=</span><span class="st">"css/mapPage.css"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb8-5" data-line-number="5"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb8-6" data-line-number="6"></a>
<a class="sourceLine" id="cb8-7" data-line-number="7"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb8-8" data-line-number="8"> <span class="kw"><h1></span>Sample Map<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb8-9" data-line-number="9"> <span class="kw"><div</span><span class="ot"> id=</span><span class="st">"map_canvas"</span><span class="kw">></div></span></a>
<a class="sourceLine" id="cb8-10" data-line-number="10"></a>
<a class="sourceLine" id="cb8-11" data-line-number="11"> <span class="co"><!-- Let's put our JavaScript down here </span><span class="er">-------------------------------------------</span><span class="co">--></span></a>
<a class="sourceLine" id="cb8-12" data-line-number="12"> <span class="co"><!-- Load the external JavaScript file with the map definition code --></span></a>
<a class="sourceLine" id="cb8-13" data-line-number="13"> <span class="kw"><script</span><span class="ot"> src=</span><span class="st">"js/mapPage_02.js"</span><span class="kw">></script></span></a>
<a class="sourceLine" id="cb8-14" data-line-number="14"> </a>
<a class="sourceLine" id="cb8-15" data-line-number="15"> <span class="co"><!-- Load the API in asynchronous mode and execute the initialize </span></a>
<a class="sourceLine" id="cb8-16" data-line-number="16"><span class="co"> function when done --></span></a>
<a class="sourceLine" id="cb8-17" data-line-number="17"> </a>
<a class="sourceLine" id="cb8-18" data-line-number="18"> <span class="kw"><script</span><span class="ot"> async defer</span> </a>
<a class="sourceLine" id="cb8-19" data-line-number="19"><span class="ot"> src=</span><span class="st">"https://maps.googleapis.com/maps/api/js?callback=initialize</span><span class="er">&</span><span class="st">key=</span><span class="er"><</span><span class="st">mykey>"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb8-20" data-line-number="20"> <span class="kw"></script></span></a>
<a class="sourceLine" id="cb8-21" data-line-number="21"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb8-22" data-line-number="22"><span class="kw"></html></span></a></code></pre></div>
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/js/mapPage_02.js">mapPage_02.js</a></p>
<div class="sourceCode" id="cb9"><pre class="sourceCode numberSource js numberLines"><code class="sourceCode javascript"><a class="sourceLine" id="cb9-1" data-line-number="1"><span class="kw">function</span> <span class="at">initialize</span>() <span class="op">{</span></a>
<a class="sourceLine" id="cb9-2" data-line-number="2"> <span class="kw">var</span> classroom <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">LatLng</span>(<span class="fl">35.084280</span><span class="op">,-</span><span class="fl">106.624073</span>)</a>
<a class="sourceLine" id="cb9-3" data-line-number="3"> <span class="kw">var</span> mapOptions <span class="op">=</span> <span class="op">{</span></a>
<a class="sourceLine" id="cb9-4" data-line-number="4"> <span class="dt">zoom</span><span class="op">:</span> <span class="dv">8</span><span class="op">,</span></a>
<a class="sourceLine" id="cb9-5" data-line-number="5"> <span class="dt">center</span><span class="op">:</span> classroom<span class="op">,</span></a>
<a class="sourceLine" id="cb9-6" data-line-number="6"> <span class="dt">mapTypeId</span><span class="op">:</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="va">MapTypeId</span>.<span class="at">SATELLITE</span></a>
<a class="sourceLine" id="cb9-7" data-line-number="7"> <span class="op">};</span></a>
<a class="sourceLine" id="cb9-8" data-line-number="8"> <span class="kw">var</span> map <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">Map</span>(</a>
<a class="sourceLine" id="cb9-9" data-line-number="9"> <span class="va">document</span>.<span class="at">getElementById</span>(<span class="st">"map_canvas"</span>)<span class="op">,</span></a>
<a class="sourceLine" id="cb9-10" data-line-number="10"> mapOptions)<span class="op">;</span></a>
<a class="sourceLine" id="cb9-11" data-line-number="11"><span class="op">}</span></a>
<a class="sourceLine" id="cb9-12" data-line-number="12"></a></code></pre></div>
</div>
<h3 id="simple---hybrid" class="module02a02a">Simple - Hybrid</h3>
<p><img src="images/gmaps03.png" alt="gmaps03.html preview" /> </p>
<h3 id="simple---hybrid-code" class="module02a02a">Simple - Hybrid Code</h3>
<div class="codeTable">
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/gmaps03.html">gmaps03.html</a></p>
<div class="sourceCode" id="cb10"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb10-1" data-line-number="1"><span class="dt"><!DOCTYPE </span>html<span class="dt">></span></a>
<a class="sourceLine" id="cb10-2" data-line-number="2"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb10-3" data-line-number="3"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb10-4" data-line-number="4"> <span class="kw"><link</span><span class="ot"> rel=</span><span class="st">"stylesheet"</span><span class="ot"> type=</span><span class="st">"text/css"</span><span class="ot"> href=</span><span class="st">"css/mapPage.css"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb10-5" data-line-number="5"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb10-6" data-line-number="6"></a>
<a class="sourceLine" id="cb10-7" data-line-number="7"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb10-8" data-line-number="8"> <span class="kw"><h1></span>Sample Map<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb10-9" data-line-number="9"> <span class="kw"><div</span><span class="ot"> id=</span><span class="st">"map_canvas"</span><span class="kw">></div></span></a>
<a class="sourceLine" id="cb10-10" data-line-number="10"></a>
<a class="sourceLine" id="cb10-11" data-line-number="11"> <span class="co"><!-- Let's put our JavaScript down here </span><span class="er">-------------------------------------------</span><span class="co">--></span></a>
<a class="sourceLine" id="cb10-12" data-line-number="12"> <span class="co"><!-- Load the external JavaScript file with the map definition code --></span></a>
<a class="sourceLine" id="cb10-13" data-line-number="13"> <span class="kw"><script</span><span class="ot"> src=</span><span class="st">"js/mapPage_03.js"</span><span class="kw">></script></span></a>
<a class="sourceLine" id="cb10-14" data-line-number="14"> </a>
<a class="sourceLine" id="cb10-15" data-line-number="15"> <span class="co"><!-- Load the API in asynchronous mode and execute the initialize </span></a>
<a class="sourceLine" id="cb10-16" data-line-number="16"><span class="co"> function when done --></span></a>
<a class="sourceLine" id="cb10-17" data-line-number="17"> </a>
<a class="sourceLine" id="cb10-18" data-line-number="18"> <span class="kw"><script</span><span class="ot"> async defer</span> </a>
<a class="sourceLine" id="cb10-19" data-line-number="19"><span class="ot"> src=</span><span class="st">"https://maps.googleapis.com/maps/api/js?callback=initialize</span><span class="er">&</span><span class="st">key=</span><span class="er"><</span><span class="st">mykey>"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb10-20" data-line-number="20"> <span class="kw"></script></span></a>
<a class="sourceLine" id="cb10-21" data-line-number="21"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb10-22" data-line-number="22"><span class="kw"></html></span></a></code></pre></div>
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/js/mapPage_03.js">mapPage_03.js</a></p>
<div class="sourceCode" id="cb11"><pre class="sourceCode numberSource js numberLines"><code class="sourceCode javascript"><a class="sourceLine" id="cb11-1" data-line-number="1"><span class="kw">function</span> <span class="at">initialize</span>() <span class="op">{</span></a>
<a class="sourceLine" id="cb11-2" data-line-number="2"> <span class="kw">var</span> classroom <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">LatLng</span>(<span class="fl">35.084280</span><span class="op">,-</span><span class="fl">106.624073</span>)</a>
<a class="sourceLine" id="cb11-3" data-line-number="3"> <span class="kw">var</span> mapOptions <span class="op">=</span> <span class="op">{</span></a>
<a class="sourceLine" id="cb11-4" data-line-number="4"> <span class="dt">zoom</span><span class="op">:</span> <span class="dv">8</span><span class="op">,</span></a>
<a class="sourceLine" id="cb11-5" data-line-number="5"> <span class="dt">center</span><span class="op">:</span> classroom<span class="op">,</span></a>
<a class="sourceLine" id="cb11-6" data-line-number="6"> <span class="dt">mapTypeId</span><span class="op">:</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="va">MapTypeId</span>.<span class="at">HYBRID</span></a>
<a class="sourceLine" id="cb11-7" data-line-number="7"> <span class="op">};</span></a>
<a class="sourceLine" id="cb11-8" data-line-number="8"> <span class="kw">var</span> map <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">Map</span>(</a>
<a class="sourceLine" id="cb11-9" data-line-number="9"> <span class="va">document</span>.<span class="at">getElementById</span>(<span class="st">"map_canvas"</span>)<span class="op">,</span></a>
<a class="sourceLine" id="cb11-10" data-line-number="10"> mapOptions)<span class="op">;</span></a>
<a class="sourceLine" id="cb11-11" data-line-number="11"><span class="op">}</span></a>
<a class="sourceLine" id="cb11-12" data-line-number="12"></a></code></pre></div>
</div>
<h3 id="simple---terrain" class="module02a02a">Simple - Terrain</h3>
<p><img src="images/gmaps04.png" alt="gmaps04.html preview" /> </p>
<h3 id="simple---terrain-code" class="module02a02a">Simple - Terrain Code</h3>
<div class="codeTable">
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/gmaps04.html">gmaps04.html</a></p>
<div class="sourceCode" id="cb12"><pre class="sourceCode numberSource html numberLines"><code class="sourceCode html"><a class="sourceLine" id="cb12-1" data-line-number="1"><span class="dt"><!DOCTYPE </span>html<span class="dt">></span></a>
<a class="sourceLine" id="cb12-2" data-line-number="2"><span class="kw"><html></span></a>
<a class="sourceLine" id="cb12-3" data-line-number="3"> <span class="kw"><head></span></a>
<a class="sourceLine" id="cb12-4" data-line-number="4"> <span class="kw"><link</span><span class="ot"> rel=</span><span class="st">"stylesheet"</span><span class="ot"> type=</span><span class="st">"text/css"</span><span class="ot"> href=</span><span class="st">"css/mapPage.css"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb12-5" data-line-number="5"> <span class="kw"></head></span></a>
<a class="sourceLine" id="cb12-6" data-line-number="6"></a>
<a class="sourceLine" id="cb12-7" data-line-number="7"> <span class="kw"><body></span></a>
<a class="sourceLine" id="cb12-8" data-line-number="8"> <span class="kw"><h1></span>Sample Map<span class="kw"></h1></span></a>
<a class="sourceLine" id="cb12-9" data-line-number="9"> <span class="kw"><div</span><span class="ot"> id=</span><span class="st">"map_canvas"</span><span class="kw">></div></span></a>
<a class="sourceLine" id="cb12-10" data-line-number="10"></a>
<a class="sourceLine" id="cb12-11" data-line-number="11"> <span class="co"><!-- Let's put our JavaScript down here </span><span class="er">-------------------------------------------</span><span class="co">--></span></a>
<a class="sourceLine" id="cb12-12" data-line-number="12"> <span class="co"><!-- Load the external JavaScript file with the map definition code --></span></a>
<a class="sourceLine" id="cb12-13" data-line-number="13"> <span class="kw"><script</span><span class="ot"> src=</span><span class="st">"js/mapPage_04.js"</span><span class="kw">></script></span></a>
<a class="sourceLine" id="cb12-14" data-line-number="14"> </a>
<a class="sourceLine" id="cb12-15" data-line-number="15"> <span class="co"><!-- Load the API in asynchronous mode and execute the initialize </span></a>
<a class="sourceLine" id="cb12-16" data-line-number="16"><span class="co"> function when done --></span></a>
<a class="sourceLine" id="cb12-17" data-line-number="17"> </a>
<a class="sourceLine" id="cb12-18" data-line-number="18"> <span class="kw"><script</span><span class="ot"> async defer</span> </a>
<a class="sourceLine" id="cb12-19" data-line-number="19"><span class="ot"> src=</span><span class="st">"https://maps.googleapis.com/maps/api/js?callback=initialize</span><span class="er">&</span><span class="st">key=</span><span class="er"><</span><span class="st">mykey>"</span><span class="kw">></span></a>
<a class="sourceLine" id="cb12-20" data-line-number="20"> <span class="kw"></script></span></a>
<a class="sourceLine" id="cb12-21" data-line-number="21"> <span class="kw"></body></span></a>
<a class="sourceLine" id="cb12-22" data-line-number="22"><span class="kw"></html></span></a></code></pre></div>
<p><a href="http://karlbenedict.com/GEOG485-585/sample-files/GoogleMaps/js/mapPage_04.js">mapPage_04.js</a></p>
<div class="sourceCode" id="cb13"><pre class="sourceCode numberSource js numberLines"><code class="sourceCode javascript"><a class="sourceLine" id="cb13-1" data-line-number="1"><span class="kw">function</span> <span class="at">initialize</span>() <span class="op">{</span></a>
<a class="sourceLine" id="cb13-2" data-line-number="2"> <span class="kw">var</span> classroom <span class="op">=</span> <span class="kw">new</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="at">LatLng</span>(<span class="fl">35.084280</span><span class="op">,-</span><span class="fl">106.624073</span>)</a>
<a class="sourceLine" id="cb13-3" data-line-number="3"> <span class="kw">var</span> mapOptions <span class="op">=</span> <span class="op">{</span></a>
<a class="sourceLine" id="cb13-4" data-line-number="4"> <span class="dt">zoom</span><span class="op">:</span> <span class="dv">8</span><span class="op">,</span></a>
<a class="sourceLine" id="cb13-5" data-line-number="5"> <span class="dt">center</span><span class="op">:</span> classroom<span class="op">,</span></a>
<a class="sourceLine" id="cb13-6" data-line-number="6"> <span class="dt">mapTypeId</span><span class="op">:</span> <span class="va">google</span>.<span class="va">maps</span>.<span class="va">MapTypeId</span>.<span class="at">TERRAIN</span></a>
<a class="sourceLine" id="cb13-7" data-line-number="7"> <span class="op">};</span></a>