6.15. A viewer for Web Maps
A special web application for viewing Web Maps is included in NextGIS Web (see Pic. 6.224.).
To view the Web Map press next to its name in the resource list or open the resource page and select Display in the Actions panel on the right. The following page will open:

Pic. 6.224. The interface of viewer client application
Numbers indicate: 1 – map; 2 – map panels; 3 - layer tree with layer menu buttons; 4 – dropdown list of basemaps; 5 - zoom tools; 6 - map tools; 7 - status bar and copyright.
Web client includes three main components: a map, panels, map tools.
6.15.1. Zoom and rotation
The status bar (see Pic. 6.224.) displays the current scale of the map. If you use the identify tool to click on the map, a pop-up window will show the coordinates of the point you clicked on and list map features if present in this point of the map.
You can change the scale of the map using zoom tools (see item 5 in Pic. 6.224.). To reset the map to its initial extent, press the house icon.
There are some options to work with map:
if you click on
alt + shift
simultaneously and execute round cursor movements around a monitor, a map will turn for a certain degrees to the right or to the left,if you simultaneously click on
shift
and select of the necessary part of a map on a monitor by a cursor, you will highlight this part and zoom in it on the map.
To view your current location on the map, press . See how it works in our video:
Watch on youtube.
6.15.2. Panels
On the left side of the workspace are the functional panels:
Layers
Feature identification
Share
Print
To share a link to a map or generate embed code use the function “Share” (see item 9 in Pic. 6.224., learn more), to print a map use the function “Print map” (see item 10 in Pic. 6.224., learn more).
The layer tree contains a list of all layer styles added to the web map. The panel allows:
Disable/Enable layer visibility. You can also hide parts of a layer by selecting items in the Web Map lengend. It’s helpful for big projects where one layer may contain a variety of features grouped by value of an attribute.
Open layer attribute table
Zoom map to layer
Open layer description
Change the order of the layers by dragging them within the layer tree. Refresh the page to restore the original order.
Functionality of the layer panel is presented in our video:
Watch on youtube.
6.15.3. Search
Search is performed using three sources:
Coordinates.
Attributes of layers added to a map.
Address database (OpenStreetMap or Yandex.Maps, depending on address search settings).
Results are shown as user inputs text and are sorted in this order: points on the map matching the coordinates, then feature numbers for attribute search and finally full addresses. After a click on a search result map changes extent to show selected feature.

Pic. 6.225. Feature selected in search results is displayed on the map
6.15.3.1. Search by coordinates
To find a point using the coordinates, enter the latitude and longitude in degrees, minutes and second, degrees and decimal minutes or decimal degrees (make sure to use straight single and double quotes), for example:
79 W 43 N
W 79 N 43
-79 43 (the results will contain two points: 79 W, 43 N and 43 E, 79 S)
79- 43
-79 W 43 N
79°4'14.08" W 43°4'59.37" N
-79°4'14.08" 43°4'59.37"
-79 4.25 W 43 4.95 N
-79 4.25 43 4.95
79.068493 43.079920
79.068 W 43.08 N
See how it works in our video:
Watch on youtube.
When the feature table is opened on the Web Map, you can filter features by area (read more).
6.15.5. Basemap
To change a basemap use the dropdown list (see Pic. 6.224.). By default there are the following basemaps:
None
OpenStreetMap
Basemap is a map image that is shared by thrid-party services in the Internet. Users can not influence their content. You can disable the basemap so that a white background is shown instead. If the Internet access is expected to be poor or if the Web GIS is deployed in local network without access to the Internet, it is possible to work without a basemap adding base data as WebGIS layers.
You can add other basemaps, see the instructions in Adding resources.
Note
If the Web Map is supposed to work without Internet access, edit the file with basemap settings and delete records about Google basemaps.
6.15.6. Map tools
Tools to work with the Web Map (see Pic. 6.224. item 6) named from left to the right:
Zoom in
Zoom out
Measure distance
Measure area
Vertical swipe
Show cursor coordinates/extent

Pic. 6.228. Map tools
6.15.6.1. Measuring tools
Map tools allow to measure distance (straight or segmented line) and area. Activate the tool and draw a line by clicking on the map. Double-click to finish line creation. You can draw multiple measuring lines on a map and compare results. To delete one of the measurement lines, press X on the measurement results lable. To clear selection, press the tool button again.

Pic. 6.229. Measuring distance on the Web Map
To measure area draw a custom polygon on the map. Double-click to finish the polygon.

Pic. 6.230. Measuring areas on the Web Map
Measurement units are selected in the Control panel
6.15.6.2. Swipe
Swipe makes the selected layer transparent to one side of the line.
To select a layer click on it in the layer tree (it will be highlighted in blue), then press the swipe button (see Pic. 6.231.).

Pic. 6.231. Horizontal swipe. Selected layer is marked in blue
Use the square in the center to move the swipe and the circle on the line to rotate it 90 degrees.
Swipe makes it possible to “peek” under the selected layer and compare it with the substrate or another layer on the map. The tool will be useful if we want to compare changes in the terrain by satellite images for different dates (for example, to identify forest felling or floods).

Pic. 6.232. Satellite image after applying the vertical swipe
6.15.6.3. Show extent or cursor coordinates
A field can be added to the Web Map interface to show the coordinates of the current cursor position or the extent of the visible map area. To activate it, press the button in the map tools panel.
The icon on the right indicates what is displayed. Click on it to switch between modes.

Pic. 6.233. Cursor coordinates mode

Pic. 6.234. Extent mode
6.15.7. Link to a Web Map feature
The easiest way is to zoom in on the area and copy the link via the Share panel (Pic. 6.224.)
Using specially generated GET queries you can share a link to a particular feature of a layer. The link will open with the geographical context that you can select in the Web Map settings.
All you need to do is create links in the information systems. By clicking on them users will be directed to the map with the selected feature and context.
Such links can be automatically generated by your system integrated with NextGIS Web.
Example:
You can make such a link manually. Here’s what you need:
Link to the Web Map: https://demo.nextgis.com/resource/6118/display?panel=layers
For the feature:
hl_lid - layer ID (open the layer resource page and see the number in the URL, for example https://demo.nextgis.com/resource/6114, here
hl_lid=6114
hl_attr – the name of the ID attribute field, for example
OSM_ID
;hl_val – the value of the ID field.
You can also add:
zoom - value in numbers with 1 being the minimum.
Here’s the resulting link:

Pic. 6.235. Web Map opened via the link. The link contains the ID of the layer and the ID field name and value for the selected feature