PuneetKSaxena
asked on
Change date format in xslt
Hi,
I'm using xslt to display date from xml
In xml the date is like "2009-02-11T15:55:20.283-0 8:00" , which i'm reading from xsl.
I want to change the format of date to "02-11-2009" in xsl.
How can i do that
Thanks and Regards
Puneet
I'm using xslt to display date from xml
In xml the date is like "2009-02-11T15:55:20.283-0
I want to change the format of date to "02-11-2009" in xsl.
How can i do that
Thanks and Regards
Puneet
XML:
<a>
<b id="1">
<date>2009-02-11T15:55:20.283-08:00</date>
</b>
<b id="2">
<date>2009-02-21T10:55:20.283-08:00</date>
</b>
and my xsl is
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" encoding="UTF-8"/>
<xsl:template match="/">
<html>
<head><title>Oa</title><link rel="stylesheet" type="text/css" />
</head>
<body bgcolor="#808080">
<TR>
<xsl:for-each select="a/b">
<TD width="10%" align="center"><xsl:value-of select="date"/></TD>
</TR>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
welcome
ASKER
Thanks a lot