26.0 Current Location

26.2b KML Data Returned

Back to Index

Keyhole Markup Language (KML) is a standard XML file used for storing geographic data for display in Google Earth. A full specification and related information can be obtained from Google Earth KML 2.0.

Information about the KML file can be found in the “Document” element.

DTD

<!ELEMENT Document (#PCDATA | name | description | Style | Folder)*>
<!ELEMENT timePosition (#PCDATA)>
<!ELEMENT styleUrl (#PCDATA)>
<!ELEMENT width (#PCDATA)>
<!ELEMENT LineStyle (#PCDATA | color | width)*>
<!ELEMENT Style (#PCDATA | IconStyle | LineStyle)*>
<!ATTLIST Style id CDATA #IMPLIED>
<!ELEMENT href (#PCDATA)>
<!ELEMENT w (#PCDATA)>
<!ELEMENT h (#PCDATA)>
<!ELEMENT Icon (#PCDATA | href | y | w | h | x)*>
<!ELEMENT MultiGeometry (#PCDATA | LineString)*>
<!ELEMENT TimeInstant (#PCDATA | timePosition)*>
<!ELEMENT color (#PCDATA)>
<!ELEMENT kml (#PCDATA | Document)*>
<!ELEMENT Point (#PCDATA | coordinates)*>
<!ELEMENT description (#PCDATA)>
<!ELEMENT IconStyle (#PCDATA | Icon)*>
<!ELEMENT y (#PCDATA)>
<!ELEMENT Folder (#PCDATA | name | Placemark | Folder | description)*>
<!ELEMENT LineString (#PCDATA | coordinates)*>
<!ELEMENT name (#PCDATA)>
<!ELEMENT x (#PCDATA)>
<!ELEMENT coordinates (#PCDATA)>
<!ELEMENT Placemark (#PCDATA | name | styleUrl | MultiGeometry | description | TimeInstant | Point)*>

Example kml “Current Location” Request with target specified

http://customer.zonarsystems.net/interface.php?action=showposition
&operation=current&format=kml&reqtype=dbid&target=19&version=2&logvers=3

Example kml “Current Location” Success reply (kml)

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://earth.google.com/kml/2.0">
<Document>
<name>19/Sep/2006 16:18:08</name>
<description>Last Known Location information retrieved on 19/Sep/2006 16:18:08</description>
<!-- Begin Style Definitions -->
<Style id="green_dot">
<IconStyle>
<Icon>
<href>root://icons/palette-4.png</href>
<y>160</y>
<w>32</w>
<h>32</h>
</Icon>
</IconStyle>
</Style>
<Style id="red_dot">
<IconStyle>
<Icon>
<href>root://icons/palette-4.png</href>
<y>32</y>
<w>32</w>
<h>32</h>
<x>224</x>
</Icon>
</IconStyle>
</Style>
<Style id="green_car">
<IconStyle>
<Icon>
<href>root://icons/palette-4.png</href>
<x>192</x>
<w>32</w>
<h>32</h>
</Icon>
</IconStyle>
</Style>
<Style id="cold_start_icon">
<IconStyle>
<Icon>
<href>root://icons/palette-4.png</href>
<x>96</x>
<y>96</y>
<w>32</w>
<h>32</h>
</Icon>
</IconStyle>
</Style>
<Style id="sc_one">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<y>192</y>
</Icon>
</IconStyle>
</Style>
<Style id="sc_two">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<x>32</x>
<y>192</y>
</Icon>
</IconStyle>
</Style>
<Style id="sc_three">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<x>64</x>
<y>192</y>
</Icon>
</IconStyle>
</Style>
<Style id="sc_four">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<x>96</x>
<y>192</y>
</Icon>
</IconStyle>
</Style>
<Style id="sc_five">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<x>128</x>
<y>192</y>
</Icon>
</IconStyle>
</Style>
<Style id="geofence_icon">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<h>32</h>
<w>32</w>
<x>96</x>
<y>128</y>
</Icon>
</IconStyle>
</Style>
<Style id="switched_off_icon">
<IconStyle>
<Icon>
<href>root://icons/palette-3.png</href>
<x>64</x>
<y>96</y>
<w>32</w>
<h>32</h>
</Icon>
</IconStyle>
</Style>
<Style>
<LineStyle>
<color>ffeeee17</color>
<width>4</width>
</LineStyle>
</Style>
<!-- End Style Definitions -->
<Folder>
<name>Fleet: 900_1997_kelly TagId: 1003 Type: 0 Id: 19</name>
<Folder>
<name>Last Location</name>
<description>This point is the last known location logged for this asset</description>
<Placemark>
<description>
<![CDATA[
<div align="center">
<table cellspacing="1" cellpadding="1" border="1">
<tr><td nowrap><font face="verdana" size="5">Time:</font></td>
<td nowrap><font face="verdana" size="5">2006-09-18 09:34:54-07</font></td>
</tr>
<tr> <td nowrap><font face="verdana" size="5">Speed:</font></td>
<td nowrap><font face="verdana" size="5">0.0 Mile/Hour</font></td>
</tr>
<tr> <td nowrap><font face="verdana" size="5">Heading:</font></td>
<td nowrap><font face="verdana" size="5">North </font></td>
</tr>
<tr> <td nowrap><font face="verdana" size="5">Log Reason:</font></td>
<td nowrap><font face="verdana" size="5">Switched Off Power Event </font></td>
</tr>
<tr> <td nowrap><font face="verdana" size="5">Distance Travelled:</font></td>
<td nowrap><font face="verdana" size="5">0.0 Miles</font></td>
</tr>
</table>
</div>
]]>
</description>
<styleUrl>#switched_off_icon</styleUrl>
<TimeInstant>
<timePosition>2006-09-18T09:34:54</timePosition>
</TimeInstant>
<Point>
<coordinates>-122.295077,47.4275229,0.000000</coordinates>
</Point>
</Placemark>
</Folder>
</Folder>
</Document>
</kml>

Is this api manual documents helpful?
0 out of 0 said Yes
YesNo