xsl-list
[Top] [All Lists]

Re: Re: Parsing day out of date format 10/12/00

2003-02-12 14:06:49
Awesome. Thanks Ritu.
-James


From: "Ritu" <rkama(_at_)sarvega(_dot_)com>
Date: 2003/02/12 Wed PM 04:00:08 EST
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Subject: Re: [xsl] Parsing day out of date format 10/12/00

  To get the month let's say - you would do

    <xsl:value-of select="substring(BirthDate,1,2)" />


Similarly use substring to get other parts of the date and construct the
result tree
Ritu Kama
Sarvega Inc
745, McLintock Dr
Burr Ridge
IL - 60527
----- Original Message -----
From: "James Hunt" <arcjah(_at_)fuse(_dot_)net>
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Sent: Wednesday, February 12, 2003 2:44 PM
Subject: [xsl] Parsing day out of date format 10/12/00


How would I go about parsing some xml like this:

<BirthDate>10/12/00</BirthDate>

to:

<BirthDate>
   <BirthMonth>10</BirthMonth>
   <BirthDay>12</BirthDay>
   <BirthYear>00</BirthYear>
</BirthDate>

using xsl?


Thanks,
James


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>