Difference between revisions of "VOCWiki:BCMap"

From VOC Wiki
Jump to: navigation, search
Line 34: Line 34:
 
<code><nowiki><bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap></nowiki></code> gives this:
 
<code><nowiki><bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap></nowiki></code> gives this:
 
<bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap>
 
<bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap>
 +
 +
For information on available layers, see [[online mapping#Provincial Basemap WMS]]

Revision as of 09:56, 29 February 2008

BCMap Extension

There's a custom mediawiki extension on VOCWiki which allows one to embed a map from BC Basemap.

Usage

To use this feature, write something like this in a wiki page <bcmap>lat=50.1|long=123.2</bcmap>. You must specify the center of the map using (lattitude and longitude) OR you can specify the bounding box of the map using (north and south and east and west) parameters.

Additionally, there are some optional paramaters :

  1. height: height of the map in km (default:10km)
  2. width: width of the map in km (default:10km)
  3. scale: map scale in pixels / km (default:100 pixels/km)
  4. linkscale: when you click on the map you'll be shown an image with this scale (default:2*scale)
  5. alttext: what text-only web browsers will see instead of the map (default:BC Basemap)

Example: <bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4</bcmap> gives this: <bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4</bcmap>

Advanced Usage

You can control the layers by using the following optional parameters:

  1. addlayers: comma separated list of additional layers to activate
  2. removelayers: comma seperated list of layers to deactivate

The layers names appear to be treated in a case sensitive fashion by the map server. So we do the same in the extension. Make sure you get he capitalization correct.

List of default layers:

TRIM_EBM_OCEAN TRIM_EBM_WATERBODIES TRIM_EBM_WATERCOURSES TRIM_EBM_WETLANDS TWTR_LINES TTRN_LINES TCVR_LINES TCVR_POINTS TCTR_LINES TTRN_POINTS TSRF_POINTS TCTR_POINTS WHSE_BASEMAPPING.TRIM_TEXT_ANNO TWTR_ANNO TTRN_ANNO TCVR_ANNO TCUL_LINES TCTR_ANNO BCGS_GRIDNTS_BC_COASTLINE_POLYS_125M NTS_BC_RIV_LAKE_WET_POLYS_125M NTS_BC_COASTLINE_LINES_125M NTS_BC_CONTOUR_LINES_125M NTS_BC_MANMADE_LINES_125M NTS_BC_TRANSPORT_LINES_125M NTS_BC_TRANSPORT_POINTS_125M NTS_BC_WATER_POINTS_125M NTS_BC_LANDFORM_POINTS_125M NTS_BC_ANNO NTS_GRID BC_RIV_LAKE_WET_POLYS_500M BC_WATER_LINES_500M BC_TRANSPORT_LINES_500M BC_PROV_BOUNDARIES_LINES_500M BC_MANMADE_LINES_500M BC_MAJOR_CITIES_POINTS_500M BC_WATER_POINTS_500M BC_TRANSPORT_POINTS_500M BC_SPOT_ELEVATION_POINTS_500M BC_MANMADE_POINTS_500M BC_WATER_POLYS_5KM BC_BASEMAP_LINES_5KM_water BC_BASEMAP_LINES_5KM_transport BC_BASEMAP_LINES_5KM_boundary DBM_7H_MIL_POPULATION_POINT DBM_7H_MIL_BOUNDARIES_LINE DBM_7H_MIL_DRAINAGE_LINE DBM_7H_MIL_ROADS_LINE DBM_7H_MIL_PARK_POLY DBM_7H_MIL_POLITICAL_POLY_PS DBM_7H_MIL_POLITICAL_POLY_BC DBM_7H_MIL_BATHYMETRIC_POLY

Example: <bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap> gives this: <bcmap>lat=49.9|long=123.0|scale=100|width=8|height=4|addlayers=BCGS_GRID,TRSF_ANNO|removelayers=TRIM_EBM_WATERBODIES,TRIM_EBM_WATERCOURSES</bcmap>

For information on available layers, see online mapping#Provincial Basemap WMS