ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
◀ ilDoc Overview
class.ilTextHighlighterGUI.php
Go to the documentation of this file.
1
<?
php
2
/* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3
7
class
ilTextHighlighterGUI
8
{
12
static
function
highlight
($a_dom_node_id, $a_text, $a_tpl = null)
13
{
14
global
$tpl
;
15
16
if
(!trim($a_text))
17
{
18
return
;
19
}
20
21
if
($a_tpl == null)
22
{
23
$a_tpl =
$tpl
;
24
}
25
$a_tpl->addJavascript(
"./Services/UIComponent/TextHighlighter/js/ilTextHighlighter.js"
);
26
$a_tpl->addOnLoadCode(
"il.TextHighlighter.highlight('"
.$a_dom_node_id.
"','"
.$a_text.
"');"
);
27
}
28
}
29
?>
$tpl
global $tpl
Definition:
ilias.php:8
ilTextHighlighterGUI
Text highlighter.
Definition:
class.ilTextHighlighterGUI.php:7
ilTextHighlighterGUI\highlight
static highlight($a_dom_node_id, $a_text, $a_tpl=null)
Searches for all occurences of a text (case-insensitive) and highlights it.
Definition:
class.ilTextHighlighterGUI.php:12
php
Services
UIComponent
TextHighlighter
classes
class.ilTextHighlighterGUI.php
Generated on Fri Mar 7 2025 19:01:17 for ILIAS by
1.8.13 (using
Doxyfile
)