OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: [docbook-apps] trim space off tag contents

On Sat, Apr 26, 2003 at 06:52:53PM +0200, Gabor Hojtsy wrote:
> Hi!
> We used to have a DSSSL customized DocBook sheet, but are migrating to XSL 
> based customizations. There are only a few things which are currently not 
> correctly handled by the XSL sheets.
> One of those is that we would like to strip the space from the begining of and 
> from the end of some tags. In DSSSL we simply used 'process-children-trim', 
> which trimmed the leading and ending whitespace from the child tag processed.
> It is obvious that xslt does not provide any direct solution for this. I have 
> also looked into the DocBook lib, but find nothing useful for this. Has 
> anyone solved such a problem using XSLT?

The normalize-space() function in XSL removes leading
and trailing spaces, and replaces internal sequences
of whitespace with a single space character.
If you are working with a string at that point, it could


Bob Stayton                                 400 Encinal Street
Publications Architect                      Santa Cruz, CA  95060
Technical Publications                      voice: (831) 427-7796
The SCO Group                               fax:   (831) 429-1887
                                            email: bobs@sco.com

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]