Can the current date be inserted into output through XSLT v1.0
I have an incom开发者_高级运维ing data stream that is being converted with XSLT v1.0 that incoming data does not contain any date information. what i would like, is a nice way of getting the current date to become part of the resulting output stream.
I am aware of the 2.0 current-date() type functions - unfortunately those are not available to this environment...
any thoughts/hacks/alternatives?
tia
Extension functions can be avoided.
Just pass the current date as one of the parameters to the XSLT transformation when initiating it.
This might be of use: http://exslt.org/date/functions/date-time/index.html
Date and time extension functions, implemented in some xslt processors, see referenced page for more info.
Edit
Another solution might be to pass the current datetime as a parameter to the xslt processor.
精彩评论