[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Removing line-feeds on a imported tree via documen

Subject: Re: Removing line-feeds on a imported tree via document
From: António Mota <amsmota@xxxxxxxxx>
Date: Tue, 25 Jan 2005 22:11:55 +0000
antonio mota
Ofcourse this solution of mine doesn't work the way i wanted to, too.
But i'm working on a similar one that i hope it does...

On Tue, 25 Jan 2005 19:28:13 +0000, Antsnio Mota <amsmota@xxxxxxxxx> wrote:
> I've solved my problem but i would like a more elegant solution, if
> there is one...
>
> Instead of having
> <xsl:variable name="xmldoc" select="document($xmluri)"/>
> <...>
> <xsl:copy-of select="$xmldoc/Menus/Menu" />
>
> i have now
>
> <xsl:variable name="xmldoc" select="document($xmluri)/Menus/Menu"/>
> <...>
> <Menu>
> <xsl:for-each select="$xmldoc/node()">
>         <xsl:copy><xsl:value-of select="normalize-space(.)"/></xsl:copy>
> </xsl:for-each>
> </Menu>
>
> that do the trick, but somehow i didn't like it very much.
>
> Any more sugestions? Thanks.
>
>
> On Tue, 25 Jan 2005 19:11:50 +0000, Antsnio Mota <amsmota@xxxxxxxxx> wrote:
> > Here's another interesting one. In my XSLT i have at some point
> >
> > <xsl:copy-of select="$xmldoc/Menus/Menu" />
> >
> > working ok, EXCEPT sometimes i get things like
> >
> > <Menu>
> > <Menu_K>X00066</Menu_K>
> > <Titulo>(Cada Utente)</Titulo>
> > <MenuData>SELECT Utente_K, NomeLogin
> > FROM Utente
> > WHERE UtenteTipo='U'</MenuData>
> > <MenuTipo>TXT</MenuTipo>
> > </Menu>
> >
> > Notice the line breaks on MenuData, that is causing me problems later
> > on. So i want to get rid of then. I've tryed using
> >
> > <xsl:copy-of select="normalize-space($xmldoc/Menus/Menu)" />
> >
> > because i don't understand nothing of this, but soon realise the
> > error, so i went back and define a template
> >
> >         <xsl:template match="MenuData">
> >                 <xsl:copy><xsl:value-of
select="normalize-space(.)"/></xsl:copy>
> >         </xsl:template>
> >
> > but did no good, cause it seems that only match the original MenuDatas
> > and not the imported ones.
> >
> > Any sugestions? Thanks.

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.