Overview

The GetNameFile function is used to retrieve the name of a file based on a given file ID. It is integrated within an XSLT transformation process, allowing you to dynamically fetch a file's name during XML transformations.

Function Signature

<xsl:variable name="fileName" select="ixf:GetNameFile(fileID)"/>
  • fileID: A string representing the ID of the file whose name you want to retrieve.

Usage Example

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
               xmlns:ixf="http://www.ixPath.com/Function"
               xmlns:xs="http://www.w3.org/2001/XMLSchema"
               version="2.0">

   <xsl:output method="xml" indent="yes"/>

   <xsl:template match="/">
       <iXDOC>
           <!-- Fetch the file name using the GetNameFile function -->
           <xsl:variable name="fileName" select="ixf:GetNameFile('63a1baaced01b06706b98537')"/>

           <!-- Output the file name -->
           <returnedFiles>
               <fileName>
                   <xsl:value-of select="$fileName"/>
               </fileName>
           </returnedFiles>
       </iXDOC>
   </xsl:template>

</xsl:stylesheet>
The result will be the file name.

 

Tags:
    
This wiki is hosted and managed by iXPath
Powered by XWiki 13.3 debian