xsl-list
[Top] [All Lists]

Re: output unterminated tags

2003-04-05 10:50:45
Jim,

This is a common problem for those of us who have just started delving into
XML.  What may be beneficial for you is if you could provide a sample XML
and XSLT sheet so that those of us on the list can show you how to work with
the XSL language.  I have a feeling that you need to shift your viewpoint
from a pure html line by line thought process into a more functional
programming viewpoint.  By providing the samples, we'll be able to help you
see how to use the XSL in a better manner.

Any time you need to output a particular type of element, such as 'tr', you
want the xsl processor to create an html node or element.  Using CDATA as
you have shown below creates a string that looks like a node element, but
only after the HTML has been processed (as you have seen with your output).
The way I typically do this is think about my problem in this manner:

make the table tag,
   for every row I need,
      add a start tr tag,
        apply all the templates for the individual td tags
      end the tr tag
   end the for each
end the table tag

Hopefully that makes some sense.  Again, providing the xml and xslt would
allow us to help you more.
bix




----- Original Message -----
From: "jm" <mailinglist(_at_)DiabAnalyst(_dot_)de>
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Sent: Saturday, April 05, 2003 11:38 AM
Subject: [xsl] output unterminated tags


hi all,

i want to output unterminated tags with my xslt-stylesheet
for (html)table-construction.

so i want to be able to print just

<tr>
or
</tr><tr>
or
</tr>

i tried it with <![CDATA[<tr>]]> but this put just

&lt;tr&gt;

in my html-file

thanks
jm

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>