xsl-list
[Top] [All Lists]

Re: [xsl] Manage XHTML-Output with XSL-T

2006-11-27 03:43:11

Now I want to transform this structure to the following
XHTML-Structure:

you'll need to give more information about the transformation rule that
you are trying to encode. there seems to be some information in the
<in_01>
elements, why does 
<in_01><p>a third list element</p></in_01>
become the first node of an li element, an
<in_02><p>list element as child of the third element</p></in_02>
become the second text node of teh same li, separated by a br.

If you could explain these rules in English, someone could write them
down in xslt.

- I cannot open a tag in an xsl:choose-xsl:when cause without closing
- it. 

XSLT deals with element nodes, never tags. The stylesheet has to be a
well formed XML docuement, so it's true that all tags need to be
properly balanced otherwise the XML parser will reject the stylesheet
before XSLT processor sees it.

- I cannot analyse the previous node (maybe I still didn't found the
- right function), so that I can decide if I have to open the <ul>-Tag
- or I have to close it. 

preceding-sibling::*[1] will select the previous element node, but you
can never produce open or close tags in XSLT, you need to think in terms
of a tree of nodes.

- I cannot make an XHTML-Output like
- <ul><li>...<ul><li>...</li></ul></li></ul>. Here I have the similiar
- problem as in the first topic. 

Clearly XSLT can produce that output, You need to show what you tried,
and someone could show you what;s wrong.


There is no way to put some additional content into the XML-File, so I
have a structure like
<add><in_01>...</in_01><in_01>...</in_01></add>. 

I don't understand this comment, sorry. Do you mean that the input
structure is not in your control and so you can't change it?


David


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

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