This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: date and time
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: RE: [xsl] date and time
- From: "Roger L. Cauvin" <roger at cauvin dot org>
- Date: Thu, 12 Jul 2001 22:41:12 -0500
- Reply-To: xsl-list at lists dot mulberrytech dot com
> is there a way to obtain recent system time and system date to
> put it in the result tree?
You could use a time resolver and XVRL (eXtensible Value Resolution
Language).
After running an XVRL processor, this excerpt
<hour>
<xvrl:value>
<xvrl:resolver-name>timeResolver</xvrl:resolver-name>
<xvrl:method>getHour</xvrl:method>
</xvrl:value>
</hour>
<minute>
<xvrl:value>
<xvrl:resolver-name>timeResolver</xvrl:resolver-name>
<xvrl:method>getMinute</xvrl:method>
</xvrl:value>
</minute>
would be converted to
<hour>10</hour>
<minute>35</minute>
The nice thing about XVRL is that you can extend it to resolve other kinds
of values. http://www.xvrl.org offers two Java-based XVRL parsers, JAVR and
JResolver. They include built-in resolvers for dynamically inserting the
current time, extracting data from relational databases, and "scraping" data
from web pages. They both require a JAXP-compliant XML parser (such as
Xerces/Xalan).
---
Roger L. Cauvin
roger@cauvin.org
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list