Subject: RE: Can I force XSLT to output the long-form of an element rather than the shorthand form?
From: "Passin, Tom" <tpassin@xxxxxxxxxxxx>
Date: Fri, 2 May 2003 13:48:32 -0400
|
[Chris Loschen]
> Yes, I know that '<a id="page-1"></a>' and '<a id="page-1"
> />' are supposed
> to be equivalent,
> but one of the tools my users use (XMetaL) doesn't. It throws
> a validation
> error for '<a id="page-1" />'
> but not (interestingly enough) for '<br />'. My reading of
> what they're
> trying to do is that they
> say that the shorthand form is allowed if and only if the element is
> defined as EMPTY in the
> associated DTD.
>
> In any case, I need to provide the long-form of such elements
> or my users
> can't edit the files
> in XMetaL.
Well, the "a" element is not supposed to be empty, so you could put a
single space, or let in enclose an entire element rather than just mark
a point in the document.
The XML 1.0 Rec says this about the empty elements -
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|