ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.ilWikiSearchResultsTableGUI.php
Go to the documentation of this file.
1<?php
2
25{
26 protected int $wiki_id = 0;
27
28 public function __construct(
29 object $a_parent_obj,
30 string $a_parent_cmd,
31 int $a_wiki_id,
32 array $a_results,
33 string $a_term
34 ) {
35 global $DIC;
36
37 $this->ctrl = $DIC->ctrl();
38 $this->lng = $DIC->language();
39 $ilCtrl = $DIC->ctrl();
40 $lng = $DIC->language();
41
42 parent::__construct($a_parent_obj, $a_parent_cmd);
43 $this->wiki_id = $a_wiki_id;
44
45 $this->addColumn($lng->txt("wiki_page"), "", "100%");
46 $this->setEnableHeader(true);
47 $this->setFormAction($ilCtrl->getFormAction($a_parent_obj));
48 $this->setRowTemplate(
49 "tpl.search_result.html",
50 "components/ILIAS/Wiki"
51 );
52
53 $this->setData($a_results);
54 $this->setLimit(0);
55
56 $this->setTitle($lng->txt("wiki_search_results") . ' "' . str_replace(array('"'), "", $a_term) . '"');
57 }
58
59 protected function fillRow(array $a_set): void
60 {
61 $ilCtrl = $this->ctrl;
62
63 $title = ilWikiPage::lookupTitle($a_set["page_id"]);
64 $this->tpl->setVariable("TXT_PAGE_TITLE", $title);
65 $ilCtrl->setParameterByClass(
66 "ilwikipagegui",
67 "page",
69 );
70 $this->tpl->setVariable(
71 "HREF_PAGE",
72 $ilCtrl->getLinkTargetByClass("ilwikipagegui", "preview")
73 );
74 }
75}
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setLimit(int $a_limit=0, int $a_default_limit=0)
set max.
setTitle(string $a_title, string $a_icon="", string $a_icon_alt="")
setFormAction(string $a_form_action, bool $a_multipart=false)
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
setEnableHeader(bool $a_enableheader)
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
setData(array $a_data)
Set table data.
ilLanguage $lng
static lookupTitle(int $a_page_id, string $lang="-")
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
fillRow(array $a_set)
Standard Version of Fill Row.
__construct(object $a_parent_obj, string $a_parent_cmd, int $a_wiki_id, array $a_results, string $a_term)
static makeUrlTitle(string $a_par)
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
global $DIC
Definition: shib_login.php:26