Proposed Google Mapping API XML Standard
Convention:
Text in the form of #Title# are placeholders for data. See explanations following the XML for more information.
Documentation:
Element: (required)
Format:
Ex:
Element: (optional) - Set the map center and zoom
Attribute Type Description Placeholder Required Default
lng float Map initial center longitude #Map-Center-Longitude# no -90
lat float Map initial center latitude #Map-Center-Latitude# no 35
zoom int Map initial zoom level (1-15) #Map-Zoom-Level# no 5
Format:
Ex:
Automatic Zoom Calculated with these attributes:
zoom text Set to 'auto' #Map-Zoom-Level# no --
slat float South Latitude - minx #S-Lat# no --
nlat float North Latitude - maxx #N-Lat# no --
wlng float West Longitude - miny #W-Lng# no --
elng float East Longitude - maxy #E-Lng# no --
Format:
Ex:
Note: Center of map will be calculated automatically as the center of the bounding box coordinates
Element: (optional) - Freeform element for non-API data
Attribute Type Description Placeholder Required Default
All attributes and child elements are free form.
Format:
or
.
.
.
Element: (optional) - Draw lines on a map.
Attribute Type Description Placeholder Required Default
color string Hex color value for polyline, start with # #Polyline-Hex-Color# no #0000ff
weight float Value from 0 to 1 for opacity, 1 is solid. #Polyline-Weight# no 0.5
width int Width of polyline in pixels. #Polyline-Width# no 1
(required)
Element: Child (at least 2 required) Longitude and Latitude in Decimal notation for a point on the polyline
Attribute Type Description Placeholder Required Default
lng float Longitude coordinate #Polyline-Point-Longitude# yes none
lat float Latitude coordinate #Polyline-Point-Longitude# yes none
Format:
.
.
.
Ex:
Element: (optional) - Place a marker on the map
Attribute Type Description Placeholder Required Default
lng float Longitude coordinate #Marker-Point-Longitude# yes none
lat float Latitude coordinate #Marker-Point-Longitude# yes none
icon string Name of the icon (see element) #Icon-Name# no Google red icon
Element: Child (optional) Contents of the infowindow
element contains html for the infowindow. Any html tags and text can be contained in this
element, including newline characters. Use the format to include html tags.
Element: Child (optional) Contents of the link html used to open an infowindow
element contains html for a link used to open the infowindow. Any html tags and text can be contained in this
element, including newline characters. Use the format to include html tags. Usually the form
of this element is an abbreviated version of the infowindow html.
Format:
Ex: Red Icon, small]]>
Small Red Icon]]>
Element: (optional) - Describe an icon
Attribute Type Description Placeholder Required Default
name string Icon name, used in as attribute "icon" #Icon-Name# yes none
copy string Icon name to copy attributes from #Icon-Copy# no none
xanchor int 'x' coordinate icon anchor point #Icon-X-Anchor# yes 0
yanchor int 'y' coordinate icon anchor point #Icon-Y-Anchor# yes 0
xiwanchor int 'x' coordinate infowindow anchor point #Icon-X-IWAnchor# yes 0
yiwanchor int 'y' coordinate infowindow anchor point #Icon-Y-IWAnchor# yes 0
xisanchor int 'x' coordinate icon shadow anchor point #Icon-X-ISAnchor# yes 0
yisanchor int 'y' coordinate icon shadow anchor point #Icon-Y-ISAnchor# yes 0
Element: Child (required) Icon's image file
Attribute Type Description Placeholder Required Default
src string Image file name, relative or absolute path #Icon-Source-Image# yes none
width int Pixel width of image file #Icon-Source-Image-Width# no* source
height int Pixel height of image file #Icon-Source-Image-Height# no* source
Element: Child (optional) Icon's shadow file (Defaults to source if element is missing.)
Attribute Type Description Placeholder Required Default
src string Image file name, relative or absolute path #Icon-Source-Image# yes none
width int Pixel width of image file #Icon-Source-Image-Width# no* source
height int Pixel height of image file #Icon-Source-Image-Height# no* source
Format:
.
.
.
Standards Document Rev 2.1 02/02/2006 John Coryat - USNaviguide