[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Problem with date:add
Hello again, I've done some more testing and I've no idea what's going on. I've copied a working template from my computer and uploaded it and it produces the misbehaviour I've been reporting. I've managed to set up a testarea at the following URL http://testarea.itilitycontenthub.net/date_test.aspx it's got the reported date + 30days as being 2006-02-47T10:17:00. The link just shows the XSL file used to get that output. The XML is returned from a database query, but for that page it's just <root CurrentDateTime="2006-02-17T10:17:00"> <nothing /> </root> Or whatever the currentdatetime is. I didn't mention it before, but it should be using the MSXML parser version 4, so I'm not sure if this has any problems with it. Thanks again :-) Andy -----Original Message----- From: Andrew Smith [mailto:andrew.smith@xxxxxxxxxxxxx] Sent: 17 February 2006 09:28 To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: RE: xsl-list Digest 17 Feb 2006 06:10:00 -0000 Issue 693 Hi, Thanks for that, I tried that locally as well and I'm getting the correct result, it must be something to do with the remote setup... or something. In that stylesheet though I don't import the template I've copied it directly into it. I'm going to have to look a bit deeper into this. Thanks for your help Andy -----Original Message----- Date: Thu, 16 Feb 2006 15:41:40 +0530 To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx From: Mukul Gandhi <gandhi.mukul@xxxxxxxxx> Subject: Re: RE: Problem with date:add Message-ID: <7870f82e0602160211o143cf87ck5f222e98e3d92199@xxxxxxxxxxxxxx> Given this XML file <?xml version=3D"1.0" encoding=3D"UTF-8"?> <?xml-stylesheet type=3D"text/xsl" href=3D"date_add.xsl"?> <root CurrentDateTime=3D"2006-02-16T09:42:00"> <something/> </root> and this stylesheet <?xml version=3D"1.0" encoding=3D"UTF-8"?> <xsl:stylesheet version=3D"1.0" xmlns:xsl=3D"http://www.w3.org/1999/XSL/Transform" xmlns:date=3D"http://exslt.org/dates-and-times" extension-element-prefixes=3D"date"> <xsl:import href=3D"date.add.template.xsl"/> <xsl:output method=3D"html" /> <xsl:template match=3D"/"> <xsl:call-template name=3D"date:add"> <xsl:with-param name=3D"date-time" select=3D"root/@CurrentDateTime" /> <xsl:with-param name=3D"duration" select=3D"'-P30D'" /> </xsl:call-template> </xsl:template> </xsl:stylesheet> I get correct results both with Saxon b 8.6.1 and IE 6. Regards, Mukul
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|