This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Output one record at a time


Agaram Madhavaraju wrote:

<employees>
<employee>
<name>
abc
</name>
<department>
admin
</department>
</employee>
<employee>
<name>
hij
</name>
<department>
finance
</department>
</employee>
...
... </employees>

I want to output one employee detail at a time(in HTML), using the record number(i.e the index of employee record in the xml file) as the input parameter.

How can i do that?

What the problem exactly? Cannot transform to html or select element by index?
I cannot help you with the first, you are the only man who knows how e.g. <name> should looks like in html, but second one is simple:

<xsl:apply-templates select="/employees/employee[$index]"/>

--
Oleg Tkachenko
Multiconn International, Israel


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]