Code example for single POI XML file

Print 

Copy this XML example and edit it to suit your own needs as explained in the notes below.

<?xml version="1.0" encoding="UTF-8" ?>

<item>

<poi idstr="ANWB_fietsroutes" version="1">

<title xml:lang="en-GB" mimetype="text/plain">ANWB bicycle routes: starting points</title>

  <title xml:lang="nl" mimetype="text/plain">ANWB fiets routes: start punten</title>

  <description xml:lang="en-GB" mimetype="text/plain">

    Do you know the ANWB bicycle routes? With this file your TomTom will bring you to the route’s starting point. You can cycle along the route using one of the ANWB’s bicycle maps or bicycle guides.

  </description>

  <description xml:lang="nl" mimetype="text/plain">

    Kent u de fietsroutes van de ANWB? Met behulp van dit bestand brengt TomTom u tot aan het startpunt van de route. Voor het fietsen van de routes kunt u gebruik maken van één van de fietskaarten of fietsgidsen van de ANWB.

  </description>

  <image mimetype="image/gif" url="http://plus.tomtom.com/tt_public/spm/media/poi/icon-anwb-fietsroutes.gif" usage="icon" />

<image mimetype="image/jpeg" url="http://plus.tomtom.com /tt_public/spm/media/poi/screenshot-anwb-fietsroutes.jpg" usage="preview" />

  <size>12040</size>

<download>

    <url location="http://plus.tomtom.com/tt_public/anwb/ANWB_fietsroutes.zip" content="main" size="8234"/>

  </download>

<size>10240</size>

  <targetdevice models="all" />

 <price free="true" />

<supplier>

  <name>ANWB</name>

    <image mimetype="image/gif" url="http://plus.tomtom.com /tt_public/spm/media/suppliers/anwb_sm.gif" usage="icon" />

  </supplier>

</poi>

</item>

 

Explanatory Notes

1.All information needs to be contained within the <item> element.
2.poi: This element indicates that the content item is a POI set.
3.poi idstr: This attribute must be a unique name for identifying your POI - see Naming your POI set.
4.version: A version is required. Use of this attribute allows TomTom HOME to update your POI set when an end user selects the “Update my device “ option in HOME. For your first version use “1”. If you create a new version of the same item, keep the name the same, but increase the version number.
5.title: This is the name that TomTom HOME will display for your POI set. The title may appear several times but only once per language.
6.xml:lang:This attribute indicates the language for the title. If your POI set supports multiple languages you can include multiple <title> elements with different language codes, e.g. <title xml:lang="en">Beaches</title><title xml:lang="de">Strände</title>.

       TomTom HOME will pick the most appropriate language based on the user's language setting. Note that if your POI set only supports one language, you don't need to include the xml:lang attribute, TomTom HOME will just use that description. For xml:lang, the format is <languagecode>[-<regioncode>]. <languagecode> is a two-letter ISO language code (ISO 300 66) in lowercase. <regioncode> is a two-letter ISO region code to indicate the language variant used in that region. For example, zh-CN is simplified Chinese and zh-TW is traditional Chinese. Note that in many countries, there is an official, national variant that requires no qualification. A complete list of ISO language codes can be found here. <languagecode> and <regioncode> need to be separated by a hyphen (‘-“); underscores (“_”) are not supported.

7.description: TomTom HOME uses this as a description of your POI set. You can have descriptions in multiple languages.
8.description mimetype: This attribute describes the formatting type of the description text. Currently only "text/plain" is supported.
9.image: TomTom HOME can display an image for your POI set.
10.image mimetype: This attribute is the file type of the image. Currently only "image/gif", "image/jpeg" and "image/png" are supported.
11.image url: This is the absolute URL for the location of the image on your server.
12.image usage: This defines they way that TomTom HOME displays the image. Currently this methods are supported:

"icon": TomTom HOME will display an icon in front of the item line in the list view. Icons will be scaled to fit an area of 32 by 32 pixels. It’s recommended to create the image icon at that size and aspect ratio.

"preview": TomTom HOME will display a preview image in the more info screen of your POI, for example you can display a screenshot of POI set on the Tomtom Device or an illustration clarifying the nature of your set. Preview images.  There’s no limit to the size but we recommend you keep it sensible eg. 100 x 100 or 300 x 400.

13.size: This is the size of your POI set after installation in bytes ie. it’s the total of all the file sizes  (ov2, bmp, ver etc.) added up, not considering disk block size. TomTom HOME uses this to determine if there’s enough free space on the device to install the content item. Note that the server may sometimes report the download size instead.
14.url location: This is the absolute URL for the location on your server of the zip file containing the POI set. The item can be downloaded and used (with the provided information), if (and only if) this element is present. The URL must have a proper and meaningful filename component. The filename extension (and mimetype returned by server when downloading) must fit the content, currently .zip is allowed. Only the following characters are allowed in the filename: alphanumeric (a-z, A-Z, 0-9), dash (-), underscore (_). Filename length should be a maximum of 30 characters and the whole URL needs to conform to RFC 2396.
15.content: Currently only "main" is supported.
16.url size: This is the size of your zip file in bytes. TomTom HOME may display this to indicate to the end user how long the download might take. For very small files HOME displays “tiny”.
17.targetdevice models: This indicates on which TomTom devices the content can be installed. For POI sets you should use "all".
18.price free: This indicates whether the content is premium or free. Currently only "true" is supported.
19.supplier: TomTom HOME can display the name and logo of the supplier of the POI set.
20.supplier name: Here you can enter your name or your company’s name.
21.supplier image: TomTom HOME can display your company logo, you need to define the mime type and absolute URL to the location of the image on your server. If you select usage="icon" the image will be scaled to a 32 x 32 image. Since icons will be scaled to a square aspect ratio it’s a good idea to have the image for such an icon to also be in a square aspect ratio, to prevent distortion.