Error Accessing The Date Module
| Newsgroups | gmane.text.xml.xslt.extensions |
|---|---|
| Message-ID | <[email protected]> |
Hi, I have installed the lastest version of Xerces-J 2.6.2 and Xalan-J 2.6.0 and I still cannot get the date module to work. Also, I'm using Windows 2000 Professional Service Pack 4. At this time, I'm getting the following error message:
BEGIN ERROR:
date.date.function.xsl: This file is not valid: Unexpected element
Note: In XMLSpy 2004 Rel. 3, it seems to be an error with the element, 'xsl:param'.
END ERROR:
Here are the file that I'm using:
date_time.xsl: XSL File
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:date="http://exslt.org/dates-and-times"
extension-element-prefixes="date">
<xsl:import href="C:\Applications\exslt\date\date.xsl"/>
<xsl:template match="//this[ . = 'todaysDate' ]">
<xsl:value-of select="date:date-time()"/>
</xsl:template>
</xsl:stylesheet>
date_time.xml: XML File
<?xml version="1.0"?>
<?xml-stylesheet version="1.0" type="text/xsl" href="C:\Applications\fop-0.20.5\date_time2.xsl"?>
<test>
<this>todaysDate</this>
<this>nogo</this>
</test>
In short, I would like to replace an element value, todaysDate, within in an XML file
with the current date and time. If anyone has any ideas as to how to resolve this issue, please post to the group and thanks in advance.
-Conrad