This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: xml too big
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: RE: [xsl] xml too big
- From: "Jarno Elovirta" <jarno at codeonline dot com>
- Date: Wed, 18 Apr 2001 16:39:30 +0300
- Reply-To: xsl-list at lists dot mulberrytech dot com
Hip hei!
> I've trasformed some files xml in wml using xsl and xalan.
> I'm working in a wap project so I have to check if the wml files
> that I have
> generated are too big for the browser and if it is I have to
> divide the file
> in 2 or more files.
> Is it possible do this with xsl?
> How I can do it?
With an extension. Modify the Xalan Redirect extension element to write
contents into a ByteArray and to return the number of bits used by the
redirected output. Then generate each deck into a variable and test it's
size with the extension. This works, but slows things down quite
considerably. If your WML output doesn't vary a lot or is mostly text, you
could just approximate the deck size by using string-length() and
basically... make a wild quess :)
There are better solutions, but hope this helps,
Jarno - Wumpscut: I Want You
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
- References:
- xml too big
- From: CONTE Silvia (by way of MulberryTechnologies List Owner)