highlightItem(name, prefix, suffix [, encode])
Returns an item of the current context document, highlighting found terms of the last lucene search
This is a TMLScript way to put out items of a lucene search result while highlighting the found terms. It combines the functionalitites of <tml:item> and its attributes highlight, highlightprefix and highlightsuffix.
Additionally it allows to encode the item before the highlighting prefix and suffix are applied.
This method will only work when the document of the chosen context was directly retrieved from a lucene search result.
For backward compatibility there still is a method "highlightItem()" available on TMLContext whose use is discouraged since OpenWGA 5.3.
Name of the item to return
HTML code that is added before each found lucene term
HTML code that is added after each found lucene term
encode (String, optional):
A WebTML encoding in which the item text is encoded before the prefix and suffixes are applied. Accepts alle encodings that are available to the OpenWGA runtime