75 : string
76 {
78
79 $this->tpl =
new ilTemplate(
'tpl.main_menu_search.html',
true,
true,
'components/ILIAS/Search');
81 $this->tpl->setVariable(
'LABEL_SEARCH_OPTIONS', $this->
lng->txt(
"label_search_options"));
83 $this->tpl->setCurrentBlock("position");
84 $this->tpl->setVariable(
'TXT_GLOBALLY', $this->
lng->txt(
"search_globally"));
86 $this->tpl->parseCurrentBlock();
87 } else {
88 $this->tpl->setCurrentBlock("position_hid");
90 $this->tpl->parseCurrentBlock();
91 }
93 $this->tpl->setCurrentBlock('position_rep');
94 $this->tpl->setVariable(
'TXT_CURRENT_POSITION', $this->
lng->txt(
"search_at_current_position"));
95 $this->tpl->setVariable('REF_ID', $this->ref_id);
96 $this->tpl->parseCurrentBlock();
97 }
98 }
99
101 $this->tpl->setCurrentBlock('usr_search');
102 $this->tpl->setVariable(
'TXT_USR_SEARCH', $this->
lng->txt(
'search_users'));
104 $this->tpl->parseCurrentBlock();
105 }
106 $this->tpl->setVariable(
107 'FORMACTION',
109 );
110 $this->tpl->setVariable(
'BTN_SEARCH', $this->
lng->txt(
'search'));
111 $this->tpl->setVariable(
'SEARCH_INPUT_LABEL', $this->
lng->txt(
'search_field'));
112 $this->tpl->setVariable(
113 'AC_DATASOURCE',
115 );
116
117 $this->tpl->setVariable(
'IMG_MM_SEARCH',
ilUtil::img(
119 $this->
lng->txt(
"search")
120 ));
121
123 $this->tpl->setVariable(
124 'HREF_SEARCH_LINK',
126 );
127 $this->tpl->setVariable(
'TXT_SEARCH_LINK', $this->
lng->txt(
"last_search_result"));
128 }
129 $this->tpl->setVariable(
'TXT_SEARCH', $this->
lng->txt(
"search"));
130
131 return $this->tpl->get();
132 }
buildSearchLink(string $cmd, bool $async)
special template class to simplify handling of ITX/PEAR
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
static img(string $a_src, ?string $a_alt=null, $a_width="", $a_height="", $a_border=0, $a_id="", $a_class="")
Build img tag.
static initjQuery(?ilGlobalTemplateInterface $a_tpl=null)
inits and adds the jQuery JS-File to the global or a passed template