Google Maps v2

From Mapping on MediaWiki
Jump to: navigation, search

Note: this mapping service has been detracted since Maps 1.0 and has been removed in Maps 1.1.

Google Maps v2
What:
A web mapping service application and technology provided by Google, free for non-commercial uses.
Licence:
Google Maps v2 licence
Parameter value:
googlemaps2
Parameter aliases:
More info:
Google Maps v2

Google Maps v2 is one of the mapping services natively supported by the Maps and Semantic Maps extensions. It can be used with:

Google Maps specific properties

This mapping service defines several of it's own parameters that are supported by most of the features implementing this service.

Controls

Parameter: controls=

Possible values: auto,large, small, large-original, small-original, zoom, type, type-menu, overview-map, scale, nav-label, overlays

This parameter determines the controls that will be placed on your Google Maps map, and determine how the user will be able to interact with the map. Values are separated with comma's. You can set the default in the settings file.

Example:

controls=small, nav-label, overview-map, scale

Note that some combinations are not possible, for example type and type-menu.

Types

Maps displaying a pop-up on a Google maps map with multiple map types.

Parameter: types=

Possible values: normal, satellite, hybrid, physical, earth, sky, moon, moon-elevation, mars, mars-elevation, mars-infrared

The map types the user will be able to choose in the map type selector control. Values are separated with comma's. You can set the default.

Example:

types=hybrid,satellite,earth,physical

Maps allowed to also use the associated Google Maps API map type names. However, this support has been removed in 0.5.

Type

Maps displaying a Google Sky map with multiple markers and overview map.

Parameter: type=

Possible values: See types.

The map type, in other words: the one the map will show when the page is loaded. You can set the default.

Example:

type=hybrid

Overlays

Parameter: overlays=

Possible values: wikipedia, photos, webcams, videos

A comma separated list of values indicating which overlays a user should be able to choose from. If you do not provide any values, the defaults will be used. To not show any overlays, simply do not pas along the 'overlay' control for the 'controls=' parameter. Each overlay can be shown at page load by adding a '-1' to the end of it's value. You can set the default.

Example:

overlays=wikipedia-1,webcams,photos-1

Autozoom

Parameter: autozoom=

Possible values: on, off

This value determines whether you will be able to zoom in and out using your the scroll wheel of your mouse. You can set the default.

Example:

autozoom=off


Maps displaying a Google Earth map with Wikipedia and Images overlays.

Google Maps specific settings

Furrealz? That's marvoelusly good to know.

Default map types

The default Google Maps map types. This are the map types the user will be able to choose in the map type selector control. This value will only be used when the user does not provide one.

Default: $egMapsGoogleMapsTypes = array('normal', 'satellite', 'hybrid', 'physical');

Default map type

The default map type, in other words: the one the map will show when the page is loaded. This value will only be used when the user does not provide one.

Default: $egMapsGoogleMapsType = 'normal';

Default map controls

The default controls for Google Maps. This value will only be used when the user does not provide one.

Default: $egMapsGMapControls = array('auto', 'scale', 'type', 'overlays');

Default overlays

The default overlays for Google Maps, and whether they should be shown at page-load. This value will only be used when the user does not provide one.

Default: $egMapsGMapOverlays = array('photos' => false, 'videos' => false, 'wikipedia' => false, 'webcams' => false);

Default autozoom

The default value for enabling or disabling the autozoom of a map. This value will only be used when the user does not provide one.

Default: $egMapsGoogleAutozoom = true;

Map name prefix

The Google Maps map name prefix. It can not be identical to the one of another mapping service. Unless you know what you are doing, it's discouraged to modify this value.

Default: $egMapsGoogleMapsPrefix = 'map_google';

Google Maps usage examples

If you are using Maps and have a great example of Google Maps functionality, feel free to link to it below.

This documentation page applies to all (Semantic) Maps versions from 1.0 to 1.0.5.
Other versions: 0.7 – 0.7.x, 0.1 – 0.6.6      

Google Maps v2 en 1.0 1.0.5