local-dateTimeAdded by IBM on October 10, 2012 | Version 1 (Original)
|Determines the local date and time in the user’s time zone. For example, on October 13, 2006 4:04 P.M. could return 2006-10-13T16:04:17-08:00 (if the timezone is PST).
A number representing the result of now() is converted to a local date and time based on the users' time zone. If no time zone information is available, then only the date and time portion of the result of now() is returned.
The following buttons submits a purchase order form. When the button is clicked, the actions are triggered in order. First, the xforms:setvalue action uses the local-dateTime function to record the local date and time of submission. Then, the xforms:send action submits the form to the server.
<xforms:setvalue ref="timeStamp" value="local-dateTime()"/>