eGovernment Register


KML files

Google Earth uses data in KML format for place location. This page gives an example of the format that can be used for simple KML files. These can be used on your own website to invoke Google Earth in a similar fashion to that which is available from the eGR and Brent Council websites. Full details about KML are available from http://earth.google.com/kml and a list of UK local authorities using Google Earth is available from http://www.brent.gov.uk/egr.nsf/ProdByName/Google+Earth

There are two instances of Lat/Long values because one specifies the location (Point), the other specifies the camera viewpoint (LookAt). A KML file might contain several locations but would normally specify only one viewpoint at a time. There are numerous other elements in KML which provide more sophisticated facilities.

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://earth.google.com/kml/2.0">
  <Placemark>
    <description><![CDATA[Brent Town Hall<br>Wembley, HA9 9HD]]></description>
    <name>Brent Town Hall</name>
    <LookAt>
        <longitude>-0.2740</longitude>
        <latitude>51.5665</latitude>
        <range>300.0</range>
        <tilt>0</tilt>
        <heading>0</heading>
    </LookAt>
    <visibility>1</visibility>
    <Point>
        <extrude>1</extrude>
        <altitudeMode>relativeToGround</altitudeMode>
        <coordinates>-0.2740,51.5665,50</coordinates>
    </Point>
  </Placemark>
  </kml>






This code can be saved as a kml file such as Brent TH.kml

You can generate KML files from Google Maps using a URL in this format - http://maps.google.co.uk/maps?q=xxx&output=kml but you don't have any control over the contents of the KML file.

Bookmarks: 
© Brent Council 2005-9 & Disclaimer | All rights reserved | Privacy Policy | Feedback - Please send us your comments
This website contains information about suppliers and products which are associated with e-Government in UK Local Authorities. All brand names, company names, logos and trademarks are acknowledged as the property of their respective owners.
Last updated : 08/21/2007 04:20:42 PM
This feature will return shortly ...