Dreamweaver Extensions

Working with XML content

Open the menu.xml file in Dreamweaver (File -> Open), to change the content of your menu. Also, you can open the XML content file through FlashDevelopment24 Wizard (Right click on Flash Object, then FlashDevlopment24 Wizard -> Christmas Flash Menu). After that, in the category of 'General', click the 'Edit' button near the 'Source' field.

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

<?xml version="1.0" encoding="utf-8"?>
<navigation>
   <item caption="CAPTION 01" link="empty.html" target="_self" />
   <item caption="CAPTION 02">
      <item caption="Caption 1" link="empty.html" target="_blank" />
      <item caption="Caption 2" link="empty.html" target="_blank" />
      <item caption="Caption 3" link="empty.html" target="_blank" />
      <item type="link" caption="Link caption 1" margin_top="5" link="empty.html" target="_blank" />
      <item type="link" caption="Link caption 2" link="empty.html" target="_blank" />
   </item>
   <item caption="CAPTION 03">
      <item type="title" margin_top="5" margin_bottom="5" caption="SUB-MENU" />
      <item type="img" src="photos/photo01.png" width="75" height="50" link="empty.html" target="_self" />
      <item type="text" margin_bottom="5" caption="Short text" />
      <item type="link" caption="Link caption 1" link="empty.html" target="_self" />
      <item type="link" caption="Link caption 2" link="empty.html" target="_self" />
      <item type="separator"/>
      <item type="link" caption="Link caption 3" link="empty.html" target="_self" />
   </item>
   <item caption="CAPTION 04" link="empty.html" target="_self" />
</navigation>

The structure of menu consists of four root-menu sections.

First root-menu section has no sub menus and has its own link.

Second root-menu section consists of five items. The first, second and third are root items. The fourth and the fifth are hyperlinks (fourth item has additional attribute like margin).

Third root-menu section consists of seven items. The first item is a title. Second is an image that has its own link and size. Third is a short text, it has additional margin attribute. The fourth and the fifth are links. The sixth item is a separator. The seven item is a link.

Fourth root-menu section has no sub menus and has its own link.

<navigation>

Description
Main tag and contains the structure of the navigation menu.

<item>

Description
Contains the menu item.

Attributes

  • caption, The caption of the menu item.
  • type, The type of the menu item. Can have additional values:
    • title, The title of the sub menu.
    • img, Image. Tag <item> should have additional attributes: src, width and height.
    • text, Simple text. Tag <item> should have only one attribute: caption.
    • link, If you use this tag, <item> represents as a hyperlink.
    • separator, Separator line. If you use this tag, <item> shouldn't have any attribute.
  • margin_top, The top margin of the menu item, in pixels.
  • margin_bottom, The bottom margin of the menu item, in pixels.
  • link, The URL from which you can obtain the document.
  • 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.

Note: If you create menu with a complex structure, use attributes margin_top and margin_bottom to justify elements of the menu.