DITA and XMetaL Discussion
XMetaL Community Forum › DITA and XMetaL Discussion › conref and mandatory attributes
-
MarcB September 29, 2015 at 2:24 pm
conref and mandatory attributes
September 29, 2015 at 2:24 pmParticipants 1Replies 2Last Activity 7 years, 5 months agoRunning XMetaL Author Enterprise 9.0.0.53 on Windows 7 Enterprise.
We use the conref feature quite extensively to distribute reused text to our documentation modules.
One example is reusing theelement from a master bookmap in multiple “local” book maps for release and version information.
So a “local” book map would have something like
In the master bookmap, we have something likeHowever, on Save of the “local” book map, XMetaL throws a parsing error, based on the fact that
requires the @version attribute. Should the XMetaL parser not follow the conref and notice that the reused
element is present and correct? On a side note: we tried shutting the parser up by inserting a “local” @version attribute, but found that in production (Webworks ePublisher/Automap), the “local” value trumps the conref.
Derek Read September 29, 2015 at 8:48 pm
Reply to: conref and mandatory attributes
September 29, 2015 at 8:48 pmAny attribute (or element) that is required by the DTD (and therefore the XML Recommendation) must be in the document otherwise the document is considered invalid and XMetaL Author (and any other validating XML parser) will notify you via a validation error.
In this case I suspect you will need to use the value “-dita-use-conref-target”. That will allow it to pass the basic XML validation test against the DTD, and it should cause tools like the DITA OT or whatever else you are using to pull in the value specified in the target (using the rules defined by the DITA specs).
See: http://docs.oasis-open.org/dita/v1.1/OS/langspec/common/ditauseconreftarget.html
-
AuthorPosts
- You must be logged in to reply to this topic.