Moxi Media Inc.
<BUTTON> Tree View | Discussion Forum

IMF Developer's Guide » Site Configuration » <BUTTON>  

The <BUTTON> element defines a button in the toolbar above the map. A button causes something to happen when the icon is pressed, while a tool sets a mode that causes something to happen when the user clicks on the map. Tools and buttons are displayed in the order that they appear within the <TOOLBAR> element, and a the <SPACE> element can be used to add spacing between buttons and tools. To add a space, define a tool as follows:

See also: tool examples and tool image gallery.

Frequency Parent Elements (this element is valid within):
PO+ <TOOLSET>
   

Attributes Description
name The name of the button. All buttons and tools in a toolset must have unique names. Required.
url The URL that will be executed when the button is clicked. The URL can contain the special variable $IMF to specify that the document is relative to the IMF installation directory. Absolute URLs may also be used. URLs that don't start with http: or $IMF are resolved relative to the location of the XML file. Required.
target The name of the frame that the URL will be executed in. Use "_blank" to execute it in a new browser window. Required.
hint The pop-up tip that will appear when the user moves the mouse over the tool. Required.
status The message that will appear in the browser's status area when the user moves the mouse over the tool. Required.
help The URL of the text file containing help text for automatically generated help. If this attribute is present and if the text can be read from the URL, the text in the URL will appear beside the icon in the help document. If this attribute is empty, the text in the status attribute will be used instead. The URL can contain the special variable $IMF to specify that the document is relative to the IMF installation directory. Absolute URLs may also be used. URLs that don't start with http: or $IMF are resolved relative to the location of the XML file. Optional.
graphic The URL of the image for the tool. The URL can contain the special variable $IMF to specify that the document is relative to the IMF installation directory. Absolute URLs may also be used. URLs that don't start with http: or $IMF are resolved relative to the location of the XML file. Required.
width The width of the tool image, in pixels. Required.
height The height of the tool image, in pixels. Required.
   

Frequency Description (in this context)
PO+ The <BUTTON> element is optional, and may appear multiple times within the <TOOLSET> element.
   

Example:

<BUTTON name="Print"
        url="$IMF/imfPrintScaledMapForm.jsp"
        target="dataFrame"
        hint="Print"
        status="Create a scaled map in PDF format that you can print."
        help="$IMF/help/en/printMap.txt"
        graphic="$IMF/tools/print_1.gif"
        width="16"
        height="16" />