s
Dreamweaver Extensions

Working with XML content

Open the locations.xml file in Dreamweaver (File -> Open), to change the content of your map.

The following example shows the basic structure of the content XML file:

<?xml version="1.0" encoding="utf-8"?>
<map>
   <location caption="Appartaments 1" lat="39.754957" long="-105.004666" photo="photo.jpg" link="read_more.html" target="_blank">
      <!-- Here you can create any quantity of parameters of the description for your object-->
      <param caption="Caption 1">Text line 1</param>
      <param caption="Caption 2">Text line 2</param>
      <param caption="Caption 3">Text line 3</param>
      <param multiline="true">Multiline Text</param>
   </location>
   <location caption="Appartaments 2" lat="39.755957" long="-105.000666">
      <!-- Here you can create any quantity of parameters of the description for your object--> 
      <param caption="Caption 1">Text line 1</param>
      <param caption="Caption 2">Text line 2</param>
      <param caption="Caption 3">Text line 3</param>
   </location>
   <location caption="Appartaments 2" address="701 first street, Sunnyvale, CA" photo="photo.jpg">
      <!-- Here you can create any quantity of parameters of the description for your object-->
      <param caption="Caption 1">Text line 1</param>
      <param caption="Caption 2">Text line 2</param>
      <param caption="Caption 3">Text line 3</param>
      <param multiline="true">Multiline Text</param>
   </location>
</map>

In this example, parent <map> tag contains 3 child tags <location>.

In the first and second item addresses are specified through latitude and longitude and in the third item through address. All items have 3 captions (this captions can also be used to display in'Info Window' and 'Locations table'). You can add any number of caption parameters. Also you can add image as it is done in 1 and 3 items and hyperlink as in 1 item.

Note: We advice to use attribute address only in a Debug mode! Using address attribute will slow the map work!

<map>

Description
Main tag and contains your locations and their description.

<location>

Description
Contains location of an object. You can specify the location of an object on the map in two ways, using attribute lat and long or attributes address.

Important note: The position of a marker on the map can be set in two ways, through attributes lat and long or attribute address. It is more preferable to use latitude and longitude coordinates. As we advice to use attribute address only in a Debug mode. Using address attribute will slow the map work. If more than 2,500 geocode requests in a 24 hour period are received from a single IP address, or geocode requests are submitted from a single IP address at too fast a rate, the Google Maps API geocoder will begin responding with a status code of 620.

Attributes

  • marker_icon, This is an optional tag. It adds a specific icon to a particular location. The absolute or relative URL of the icon image file. A relative path must be relative to the HTML file. Absolute URLs must include the protocol reference, such as http://.
  • caption, The caption that appears in 'Info Window', which appears when mouse over marker.
  • photo, This is an optional tag. The absolute or relative URL of the image file. A relative path must be relative to the HTML file. Absolute URLs must include the protocol reference, such as http://.
  • lat, The floating-point number that represents a measure of latitude coordinates on the map at which to place the marker.
  • long, The floating-point number that represents a measure of longitude coordinates on the map at which to place the marker
  • address, The string that specifies the postal address at which to place the marker on the map. Note: Use this tag only if necessary (in extremely cases)!
  • link, The URL from which you can obtain the document. This is an optional tag. If it is set, so in 'Details panel' at the bottom of the location description, would be placed a hyperlink. On-default this link has caption 'Read more', which can be changed in settings 'Details panel'.
  • target, Specifies the window or HTML frame into which the document should be loaded. You can enter the name of a specific window or select from the following reserved target names:
    • _self specifies the current frame in the current window.
    • _blank specifies a new window.
    • _parent specifies the parent of the current frame.
    • _top specifies the top-level frame in the current window.

<param>

Description
Contains the description line of a location. This information displays in 'Details panel', which pop-ups when you click over marker or line in 'Locations table'.

Attributes

  • caption, The caption (name) of the parameter. This attribute is used as a title in description (that pop-ups after click on locations) of a location. Also this caption is used in 'Info Window' and 'Locations table' where you specify what paramters should be displayed.

    For exmaple, you write in XML all necessary parameter (captions), and then in 'Display params' of 'Info Window' and 'Locations table' you write necessary names of this parameters that you want to be displayed.

  • multiline, A Boolean value that indicates whether field is multiline (true) or not (false).