Function Reference
DocumentExtension
Determine if filename 'extension' has a configured input adapter.
Syntax:
wwprojext:DocumentExtension($extension)Parameters:
Name | Type | Description |
|---|---|---|
extension | string | The extension. |
Returns:
bool: True if extension has a configured adapter, false otherwise.Example:
<xsl:variable name="VarExtension" select="wwfilesystem:GetExtension($VarFilePath)" />
<xsl:variable name="VarIsSupported" select="wwprojext:DocumentExtension($VarExtension)" />
<xsl:if test="$VarIsSupported">
<!-- Process document -->
</xsl:if>GetConditionIsPassThrough
Determines if condition called: 'conditionName' is pass through.
Syntax:
wwprojext:GetConditionIsPassThrough($conditionName)Parameters:
Name | Type | Description |
|---|---|---|
conditionName | string | Name of the condition. |
Returns:
bool: True if pass through, false otherwise.Example:
<xsl:variable name="VarIsPassThrough" select="wwprojext:GetConditionIsPassThrough($VarConditionName)" />
<xsl:if test="$VarIsPassThrough">
<!-- Include condition markers in output -->
</xsl:if>GetConfigurationChangeID
Gets configuration change identifier.
Syntax:
wwprojext:GetConfigurationChangeID()Returns:
string: The configuration change identifier.Example:
<xsl:variable name="VarConfigChangeID" select="wwprojext:GetConfigurationChangeID()" />
<xsl:variable name="VarCacheValid" select="$VarStoredConfigID = $VarConfigChangeID" />GetContextRule
Gets context rule.
Syntax:
wwprojext:GetContextRule($ruleTypeAsString, $ruleName, $documentID, $uniqueID)Parameters:
Name | Type | Description |
|---|---|---|
ruleTypeAsString | string | The rule type as string. |
ruleName | string | Name of the rule. |
documentID | string | Identifier for the document. |
uniqueID | string | Unique identifier. |
Returns:
XPathNodeIterator: The context rule as a node set.Example:
<xsl:variable name="VarContextRule" select="wwprojext:GetContextRule('Paragraph', $VarStyleName, $VarDocumentID, $VarUniqueID)" />
<xsl:variable name="VarMarginTop" select="$VarContextRule/Rule/Properties/Property[@name='margin-top']/@value" />GetDocumentDataDirectoryPath
Gets document data directory path using 'documentID'.
Syntax:
wwprojext:GetDocumentDataDirectoryPath($documentID)Parameters:
Name | Type | Description |
|---|---|---|
documentID | string | Identifier for the document. |
Returns:
string: The document data directory path.Example:
<xsl:variable name="VarDocDataDir" select="wwprojext:GetDocumentDataDirectoryPath($VarDocumentID)" />
<xsl:variable name="VarDocXml" select="wwfilesystem:Combine($VarDocDataDir, 'document.xml')" />GetDocumentGroupPath
Gets document group path using 'documentID'.
Syntax:
wwprojext:GetDocumentGroupPath($documentID)Parameters:
Name | Type | Description |
|---|---|---|
documentID | string | Identifier for the document. |
Returns:
string: The document group path.Example:
<xsl:variable name="VarGroupPath" select="wwprojext:GetDocumentGroupPath($VarDocumentID)" />
<span class="breadcrumb"><xsl:value-of select="$VarGroupPath" /></span>GetDocumentID
Gets document identifier from document file pathname.
Syntax:
wwprojext:GetDocumentID($documentPath)
wwprojext:GetDocumentID($documentPath, $groupID)Parameters:
Name | Type | Description |
|---|---|---|
documentPath | string | Full pathname of the document file. |
groupID | string | Identifier for the group. |
Returns:
string: The document identifier as string.Example:
<xsl:variable name="VarDocID" select="wwprojext:GetDocumentID($VarFilePath)" />
<xsl:variable name="VarDocData" select="wwprojext:GetDocumentDataDirectoryPath($VarDocID)" />GetDocumentPath
Gets document path using 'documentID'.
Syntax:
wwprojext:GetDocumentPath($documentID)Parameters:
Name | Type | Description |
|---|---|---|
documentID | string | Identifier for the document. |
Returns:
string: The document path.Example:
<xsl:variable name="VarDocPath" select="wwprojext:GetDocumentPath($VarDocumentID)" />
<xsl:variable name="VarDocName" select="wwfilesystem:GetFileName($VarDocPath)" />GetDocumentsToGenerateChecksum
Get string representing all documents in project so checksum can be generated.
Syntax:
wwprojext:GetDocumentsToGenerateChecksum()Returns:
string: A string representing documents for generating checksum.Example:
<xsl:variable name="VarDocsChecksum" select="wwprojext:GetDocumentsToGenerateChecksum()" />
<xsl:variable name="VarCacheKey" select="wwstring:Checksum($VarDocsChecksum)" />GetFormatID
Gets format identifier.
Syntax:
wwprojext:GetFormatID()Returns:
string: The format identifier as string.Example:
<xsl:variable name="VarFormatID" select="wwprojext:GetFormatID()" />
<xsl:if test="contains($VarFormatID, 'WebWorks Reverb')">
<!-- Reverb-specific processing -->
</xsl:if>GetFormatName
Gets format name.
Syntax:
wwprojext:GetFormatName()Returns:
string: The format name as string.Example:
<xsl:variable name="VarFormatName" select="wwprojext:GetFormatName()" />
<meta name="format" content="{$VarFormatName}" />GetFormatSetting
Gets 'name' format setting.
Syntax:
wwprojext:GetFormatSetting($name)
wwprojext:GetFormatSetting($name, $defaultValue)Parameters:
Name | Type | Description |
|---|---|---|
name | string | The name. |
defaultValue | string | The default value. |
Returns:
string: The format setting as string.Example:
<xsl:variable name="VarTopicExtension" select="wwprojext:GetFormatSetting('TopicFileExtension')" />
<xsl:variable name="VarOutputFile" select="concat($VarBaseName, $VarTopicExtension)" />GetGroupDataDirectoryPath
Gets group data directory path using 'groupID'.
Syntax:
wwprojext:GetGroupDataDirectoryPath($groupID)Parameters:
Name | Type | Description |
|---|---|---|
groupID | string | Identifier for the group. |
Returns:
string: The group data directory path.Example:
<xsl:variable name="VarGroupDataDir" select="wwprojext:GetGroupDataDirectoryPath($VarGroupID)" />
<xsl:variable name="VarGroupCache" select="wwfilesystem:Combine($VarGroupDataDir, 'group-cache.xml')" />GetGroupName
Gets group name using 'groupID'.
Syntax:
wwprojext:GetGroupName($groupID)Parameters:
Name | Type | Description |
|---|---|---|
groupID | string | Identifier for the group. |
Returns:
string: The group name as string.Example:
<xsl:variable name="VarGroupName" select="wwprojext:GetGroupName($VarGroupID)" />
<h2><xsl:value-of select="$VarGroupName" /></h2>GetOverrideRule
Gets override rule.
Syntax:
wwprojext:GetOverrideRule($ruleTypeAsString, $ruleName, $documentID, $uniqueID)Parameters:
Name | Type | Description |
|---|---|---|
ruleTypeAsString | string | The rule type as string. |
ruleName | string | Name of the rule. |
documentID | string | Identifier for the document. |
uniqueID | string | Unique identifier. |
Returns:
XPathNodeIterator: The override rule node set.Example:
<xsl:variable name="VarOverrideRule" select="wwprojext:GetOverrideRule('Character', $VarStyleName, $VarDocumentID, $VarUniqueID)" />
<xsl:variable name="VarBold" select="$VarOverrideRule/Rule/Properties/Property[@name='font-weight']/@value" />GetProjectBaseFormatVersion
Gets the project's Base Format Version value.
Syntax:
wwprojext:GetProjectBaseFormatVersion()Returns:
string: The version string as major.minorExample:
<xsl:variable name="VarFormatVersion" select="wwprojext:GetProjectBaseFormatVersion()" />
<xsl:if test="$VarFormatVersion >= '2024.1'">
<!-- Use newer feature -->
</xsl:if>GetProjectDataDirectoryPath
Gets project data directory path.
Syntax:
wwprojext:GetProjectDataDirectoryPath()Returns:
string: The project data directory path.Example:
<xsl:variable name="VarDataDir" select="wwprojext:GetProjectDataDirectoryPath()" />
<xsl:variable name="VarCachePath" select="wwfilesystem:Combine($VarDataDir, 'cache.xml')" />GetProjectDirectoryPath
Gets project directory path.
Syntax:
wwprojext:GetProjectDirectoryPath()Returns:
string: The project directory path.Example:
<xsl:variable name="VarProjectDir" select="wwprojext:GetProjectDirectoryPath()" />
<xsl:variable name="VarCustomCss" select="wwfilesystem:Combine($VarProjectDir, 'custom.css')" />GetProjectDocumentsCount
Gets project documents count.
Syntax:
wwprojext:GetProjectDocumentsCount()Returns:
long: The project documents count.Example:
<xsl:variable name="VarTotalDocs" select="wwprojext:GetProjectDocumentsCount()" />
<xsl:variable name="VarStatus" select="wwprogress:SetStatus(concat('Processing ', $VarTotalDocs, ' documents'))" />GetProjectFilesDirectoryPath
Gets project files directory path.
Syntax:
wwprojext:GetProjectFilesDirectoryPath()Returns:
string: The project files directory path.Example:
<xsl:variable name="VarFilesDir" select="wwprojext:GetProjectFilesDirectoryPath()" />
<xsl:variable name="VarTemplatePath" select="wwfilesystem:Combine($VarFilesDir, 'templates', 'header.html')" />GetProjectFormatDirectoryPath
Gets project format directory path.
Syntax:
wwprojext:GetProjectFormatDirectoryPath()Returns:
string: The project format directory path.Example:
<xsl:variable name="VarFormatDir" select="wwprojext:GetProjectFormatDirectoryPath()" />
<xsl:variable name="VarStylePath" select="wwfilesystem:Combine($VarFormatDir, 'Transforms', 'styles.xsl')" />GetProjectName
Gets project name.
Syntax:
wwprojext:GetProjectName()Returns:
string: The project name.Example:
<xsl:variable name="VarProjectName" select="wwprojext:GetProjectName()" />
<meta name="project" content="{$VarProjectName}" />GetProjectReportsDirectoryPath
Gets project reports directory path.
Syntax:
wwprojext:GetProjectReportsDirectoryPath()Returns:
string: The project reports directory path.Example:
<xsl:variable name="VarReportsDir" select="wwprojext:GetProjectReportsDirectoryPath()" />
<xsl:variable name="VarReportPath" select="wwfilesystem:Combine($VarReportsDir, 'custom-report.xml')" />GetProjectTargetName
Gets project target name currently being processed.
Syntax:
wwprojext:GetProjectTargetName()Returns:
string: The project target name.Example:
<xsl:variable name="VarTargetName" select="wwprojext:GetProjectTargetName()" />
<meta name="generator" content="ePublisher - {$VarTargetName}" />GetProjectTargetOverrideDirectoryPath
Gets project target override directory path.
Syntax:
wwprojext:GetProjectTargetOverrideDirectoryPath()Returns:
string: The project target override directory path.Example:
<xsl:variable name="VarOverrideDir" select="wwprojext:GetProjectTargetOverrideDirectoryPath()" />
<xsl:variable name="VarCustomXsl" select="wwfilesystem:Combine($VarOverrideDir, 'custom.xsl')" />GetRule
Gets a rule.
Syntax:
wwprojext:GetRule($ruleTypeAsString, $ruleName)Parameters:
Name | Type | Description |
|---|---|---|
ruleTypeAsString | string | The rule type as string. |
ruleName | string | Name of the rule. |
Returns:
XPathNodeIterator: The rule as a node set.Example:
<xsl:variable name="VarRule" select="wwprojext:GetRule('Paragraph', $VarParagraphStyleName)" />
<xsl:variable name="VarFontSize" select="$VarRule/Rule/Properties/Property[@name='font-size']/@value" />GetTargetDataDirectoryPath
Gets target data directory path.
Syntax:
wwprojext:GetTargetDataDirectoryPath()Returns:
string: The target data directory path.Example:
<xsl:variable name="VarTargetDataDir" select="wwprojext:GetTargetDataDirectoryPath()" />
<xsl:variable name="VarTempFile" select="wwfilesystem:Combine($VarTargetDataDir, 'temp-data.xml')" />GetTargetFilesInfoPath
Gets target files information path.
Syntax:
wwprojext:GetTargetFilesInfoPath($targetIDAsString)Parameters:
Name | Type | Description |
|---|---|---|
targetIDAsString | string | Target identifier as string. |
Returns:
string: The target files information path.Example:
<xsl:variable name="VarFilesInfoPath" select="wwprojext:GetTargetFilesInfoPath($VarTargetID)" />
<xsl:variable name="VarFilesInfo" select="document($VarFilesInfoPath)" />GetTargetLogDirectoryPath
Gets target output directory path.
Syntax:
wwprojext:GetTargetLogDirectoryPath()Returns:
string: The target output directory path.Example:
<xsl:variable name="VarLogDir" select="wwprojext:GetTargetLogDirectoryPath()" />
<xsl:variable name="VarLogPath" select="wwfilesystem:Combine($VarLogDir, 'transform.log')" />GetTargetOutputDirectoryPath
Gets target output directory path.
Syntax:
wwprojext:GetTargetOutputDirectoryPath()Returns:
string: The target output directory path.Example:
<xsl:variable name="VarOutputDir" select="wwprojext:GetTargetOutputDirectoryPath()" />
<xsl:variable name="VarOutputPath" select="wwfilesystem:Combine($VarOutputDir, 'index.html')" />GetTargetReportsDirectoryPath
Gets target reports directory path.
Syntax:
wwprojext:GetTargetReportsDirectoryPath()Returns:
string: The target reports directory path.Example:
<xsl:variable name="VarTargetReportsDir" select="wwprojext:GetTargetReportsDirectoryPath()" />
<xsl:variable name="VarIndexReport" select="wwfilesystem:Combine($VarTargetReportsDir, 'index-report.xml')" />Last modified date: 01/12/2026