This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
> Is there an easy way to process existing DocBook XML files and add to all > elements an "id" attribute which do not already have one? >
I would do it in Java in two passes.
<xsl:template name="addId">
<xsl:when test="@id">
copy through
<xsl:otherwise>
attribute name='id'
generate-id()
/attribute
</xsl:otherwise>| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |