This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: That didnt work either! RE: How to add a "less than" or "grea ter than" sign?
- To: xsl-list at mulberrytech dot com
- Subject: RE: That didnt work either! RE: How to add a "less than" or "grea ter than" sign?
- From: "John E. Simpson" <simpson at polaris dot net>
- Date: Thu, 13 Apr 2000 14:36:08 -0400
- Cc: "'xsl-list at mulberrytech dot com'" <xsl-list at mulberrytech dot com>
- Reply-To: xsl-list at mulberrytech dot com
At 09:53 AM 4/13/2000 -0700, Selva, Francis wrote:
>But how will you make it to display ur open and close tags.It will display
>only the Type attribute name in ur output.right?.
which was in reply to:
> > From: Wendell Piez [quoting Bob duCharme]
> >
> > <xsl:element name="{@Type}">myvalue</xsl:element>
> >
The xsl:element XSLT element is used to create an element (what you're
referring to as "open and close tags") in the result tree. The difference
between using xsl:element and simply placing the literal tags in the
template is that the former allows you to "compute" the element name, based
on conditions in the source tree or elsewhere. For the latter, you have to
have a fixed string value as the element name.
The original poster was trying to do something like this:
< <elementname> >content</ <elementname> >
which would cause his stylesheet to be not well-formed.
Bob's/Wendell's solution doesn't "display only the Type attribute name"; it
displays the Type attribute *value*.
================================================================
John E. Simpson | "After they make styrofoam, what do
http://www.flixml.org | they ship it in?" (Steven Wright)
simpson@polaris.net |
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list