This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: String manipulation question
- From: Jeni Tennison <jeni at jenitennison dot com>
- To: Bodrul Haque <Bodrul dot Haque at Synergy-Logistics dot co dot uk>
- Cc: xsl-list at lists dot mulberrytech dot com
- Date: Fri, 19 Jul 2002 13:57:50 +0100
- Subject: Re: [xsl] String manipulation question
- Organization: Jeni Tennison Consulting Ltd
- References: <60779EBEFA89D311859300105A420FFB3B2DCA@syndicate.synlog.co.uk>
- Reply-to: xsl-list at lists dot mulberrytech dot com
Hi Bodrul,
> I'm having difficulties in thinking of a short and neat way of
> appending '0' in front of any number between 1-9 (if its not already
> there).
Use the format-number() function:
format-number($number, '00')
> [And appending a '20' for a year format (if its not already there)].
I'm sure David C. will come up with something neat.
Cheers,
Jeni
---
Jeni Tennison
http://www.jenitennison.com/
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list