Skip to content

Instantly share code, notes, and snippets.

@jessgusclark
Created April 18, 2016 17:44
Show Gist options
  • Save jessgusclark/70be78ee68a206af18f7203ce152eb93 to your computer and use it in GitHub Desktop.
Save jessgusclark/70be78ee68a206af18f7203ce152eb93 to your computer and use it in GitHub Desktop.
Get Files in Folder
<!-- static folder to look for data files: -->
<xsl:variable name="data-folder" select="'/pcf/data'" />
<xsl:variable name="data-location" select="concat($ou:root, $ou:site, $data-folder)" />
<!-- Create Sorted Version First, this has to happen here so we can use preceding-sibling later -->
<xsl:variable name="sortedcopy">
<xsl:for-each select="doc($data-location)/list/file">
<xsl:sort select="." order="ascending"/>
<xsl:copy-of select="."/>
</xsl:for-each>
</xsl:variable>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment