Skip to content

Instantly share code, notes, and snippets.

@loonix
Created October 26, 2017 09:41
Show Gist options
  • Save loonix/86d8a8a6ce31cc621db41f711405f9a3 to your computer and use it in GitHub Desktop.
Save loonix/86d8a8a6ce31cc621db41f711405f9a3 to your computer and use it in GitHub Desktop.
This will format a xsl-fo date to "DD/MM/YYY HH:MM" from a format "YYYY-MM-DDTHH:MM:SS
<!--This will format a date to "DD/MM/YYY HH:MM" from a format "YYYY-MM-DDTHH:MM:SS"-->
<xsl:variable name="dt" select="./When"/>
<xsl:value-of select="concat(substring($dt, 9, 2),'/',substring($dt, 6, 2),'/',substring($dt, 1, 4),' ', substring($dt, 12, 2),':',substring($dt, 15, 2))"/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment