[Home] [By Thread] [By Date] [Recent Entries]
On 03/02/10 15:26, Syd Bauman wrote:
I took note from John Cowan that comments can be used Syd! I'm ignoring certain values (simplicity). So far I've generated <element name='doc'>
<oneOrMore>
<element name='dateTime'>
<data type='string'>
<param
name='pattern'><!--
Year -->(\[Y(01|0001)?\][^\[]?)<!--
Month -->(\[M(1|01)?\]?[^\[]?)<!--
Day -->(\[D(1|01)?\])?<!--
Hour -->(T\[H[01]{0,2}\]:<!--
Minutes -->\[m(1|01)?\]:<!--
Seconds -->\[s(1|01)?\]\.<!--
decimal seconds -->\[f(1|01|001)?\])?</param>
</data>
</element>with test data of <doc> <dateTime>[Y0001]-[M01]-[D]</dateTime> <dateTime>[Y]@[M]@[D]</dateTime> <dateTime>[Y0001]-[M01]-[D1]</dateTime> <dateTime>[Y]-[M1]-[D1]</dateTime> <dateTime>[Y]-[M]-[D]T[H]:[m1]:[s].[f]</dateTime> <dateTime>[Y][M]-[D01]T[H01]:[m01]:[s01].[f001]</dateTime> <dateTime>[Y][M]-[D01]T[H01]:[m01]:[s01].[f001]</dateTime> <!-- Errors --> <dateTime>[Y100][M][D]T[H]:[m]:[s].[f]</dateTime> <dateTime>[Y][M100][D]T[H]:[m]:[s].[f]</dateTime> <dateTime>[Y][M][D10]T[H]:[m]:[s].[f]</dateTime> <dateTime>[Y][M][D10]T[H]:[m10]:[s].[f]</dateTime> <dateTime>[Y]-[M]-[D01]T[H01]:[m01]:[s0001].[f001]</dateTime> </doc> and exclusions of YWw for 'Two thousand and ten'
MNn for December
Dlo for 31st
DWo for twentiethIts for a graph X axis, using dates. As you see, we only need the Y M D H m s parts which makes it a little easier. I thought someone may have done it already Thanks though. Appreciated. regards -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk
|

Cart



