processHtmlΒΆ

This function replaces abstract internal links contained in an HTML text by generated URLs.

Parameters:

_value
Html value string to process.
_type
URL type. Either “server” (server-relative URL) or “absolute”. Default is “server”

Usage in Thymeleaf:

<div data-th-text="${portal.processHtml({'_value=some text'})}">Text</div>

Usage in XSLT:

<xsl:stylesheet version="2.0" exclude-result-prefixes="#all"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:portal="urn:enonic:xp:portal:1.0">

  <xsl:template match="/">
    <xsl:value-of select="portal:processHtml('_value=some text')"/>
  </xsl:template>

</xsl:stylesheet>