User Guide
214 Chapter 11: Tag Libraries and Editors
Adding a tag to Tag Chooser
To add the cfweather tag to the Tag Chooser:
1 Modify the TagChooser.xml file in the Configuration/Taglibraries/CFML folder by adding a
new category called Third Party Tags, which features the
cfweather tag, as shown in the
following example:
<category name="Third Party Tags" icon="icons/Elements.gif"
reference='CFML'>
<element name="cfweather" value='cfweather zip=""
temperaturescale="fahrenheit">' />
</category>
Note: On multiuser platforms, the TagChooser.xml file also exists in the user’s Configuration folder.
For more information regarding multiuser platforms, see the discussion in “Registering the tag in the
tag library” on page 211.
2 Verify the cfweather tag now appears in the Tag Chooser by performing the following steps:
■ Select Insert > Tag.
■ Expand the CFML Tags group.
■ Select the Third Party Tags group that appears at the bottom of the Tag Chooser.
■ The cfweather tag appears in the list box on the right.
■ Select cfweather, and click the Insert button.
The tag editor should appear.
Tag editor APIs
In order to create a new tag editor, you must provide an implementation for the inspectTag(),
validateTag(), and applyTag() functions. For an example of an implementation, see
“Creating a tag editor UI” on page 212.
inspectTag()
Availability
Dreamweaver MX.
Description
The function is called when the tag editor first appears. The function receives as an argument the
tag that the user is editing, which is expressed as a
dom object. The function extracts attribute
values from the tag that is being edited and uses these values to initialize form elements in the
tag editor.
Arguments
tag
• The tag argument is the DOM node of the edited tag.
Returns
Dreamweaver expects nothing.