This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: [newbie]use of xsl:if {RE: XSL to handle display mutiple pages}
- To: "'xsl-list at mulberrytech dot com'" <xsl-list at mulberrytech dot com>
- Subject: RE: [newbie]use of xsl:if {RE: XSL to handle display mutiple pages}
- From: Kay Michael <Michael dot Kay at icl dot com>
- Date: Fri, 3 Nov 2000 14:41:57 -0400 (EST)
- Reply-To: xsl-list at mulberrytech dot com
> I started working on XSL to handle display mutiple pages in
> HTML. The
> idea I tried was simple, count number of records until max
> records per page
> reaches. At that time, I close of the current page/table,
> add a page break
> and start the next page/table. But such logic seems does not
> seems to be
> allowed in xsl blocks such as xsl:if.
It sounds simple, but XSLT isn't that kind of programming language. It is
stateless and non-sequential, so you can't count things in a variable and
take action when the variable reaches a particular value. Think in terms of
functions: how does the input relate to the output. If you want to generate
an object in the output that corresponds to 20 objects in the input, write a
template rule that reads 20 objects from the input and writes one object in
the output.
Mike Kay
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list