Subject: RE: [xsl]how to mix two trees From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx> Date: Mon, 7 Oct 2002 14:56:25 +0100 |
Change your XML design, use <question-ref id="1">, not <question_1>. It's very poor design to build meaning into the structure of your XML element names, and it will certainly make your XSLT coding much harder. Michael Kay Software AG home: Michael.H.Kay@xxxxxxxxxxxx work: Michael.Kay@xxxxxxxxxxxxxx > -----Original Message----- > From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx > [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of > Tiago Freire > Sent: 07 October 2002 13:11 > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > Subject: [xsl]how to mix two trees > > > hello, I am having a headache on starting XSLT, and I have to do the > following: > given a tree like: > <result> > <exercise> > <row> > <exercise_id>1</exercise_id> > <exercise_title>XSLT Foo</exercise_title> > <exercise_question> > She sells sea sehells on the ____<question_1 />. <br /> > Fuzzy wuzzy was a _____<question_2 /> > </exercise_question> > </row> > </exercise> > <questions> > <row> > <question_id>1</question_id> > <question_order>1</question_order> > <question_options> > <item>Seashore</item> > <item>Pier</item> > </question_options> > </row> > <row> > <question_id>1</question_id> > <question_order>2</question_order> > <question_options> > <item>anemone</item> > <item>bear</item> > <item>butterfly</item> > </question_options> > </row> > </questions> > </result> > I'd have to reconstruct the result in HTML, substituting the > <question_ > /> tags in he exercise with the <row> contents belongingto the > corresponding <question_order>. > Note: the XML design can be changed(any places on where to learn good > XML design?), but we will always have these result sets with one > exercise having one or more questions in it. > > Thanks in advance, > Tiago Freire > > > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl]how to mix two trees, Tiago Freire | Thread | RE: [xsl] sum function used for val, TSchutzerWeissmann |
RE: [xsl] xsl:number counting "cous, Gustaf Liljegren | Date | [xsl] Effecient element "filtering", Edward L. Knoll |
Month |