The <metadefault> Tag
Metadata is usually embedded inside a content item using the <wmmeta>
tag. However, this can be a chore for lots of content items, so to make
things easier, you can specify default metadata settings, using the
<metadefault> tag.
Specify this tag before the content items in question, and those content items
will all be tagged with the metadata you set.
Like the attrdefault tag, this tag can be used either in a
scoped mode, or in a command mode.
Scoped Mode
"Scoped" mode uses opening (<metadefault>) and closing
(</metadefault>) tags; the metadata is only set on content items
between the two tags.
Command Mode
Command mode uses standalone tags (<metadefault ... />); the
metadata are set until the end of the WebMake file, or until you change
them with another <metadefault> tag.
Attributes
-
name
-
the metadatum's name, e.g. Title, Section,
etc. This is required.
-
value
-
the metadatum's value. This is optional. If the
value is not specified, the metadatum will be removed from the list of
default metadata.
Example
Using the scoped style:
<metadefault name="section" value="tags_and_attributes">
<content name="chunk_1.txt">...</content>
<content name="chunk_2.txt">...</content>
<content name="chunk_3.txt">...</content>
<content name="chunk_4.txt">...</content>
</metadefault>
Or, in the "command" style:
<metadefault name="section" value="tags_and_attributes" />
<content name="chunk_1.txt">...</content>
<content name="chunk_2.txt">...</content>
<content name="chunk_3.txt">...</content>
<content name="chunk_4.txt">...</content>
<metadefault name="section" />
|