24 include_once(
"Services/Table/classes/class.ilTable2GUI.php");
44 $this->
addColumn($lng->txt(
"pg"),
"",
"");
45 $this->
addColumn($lng->txt(
"cont_internal_links"),
"",
"");
49 "Modules/LearningModule");
50 $this->lm_id = $a_lm_id;
51 $this->lm_type = $a_lm_type;
54 $this->
setTitle($lng->txt(
"cont_internal_links"));
74 $this->tpl->setVariable(
"TXT_PAGE_TITLE", $a_set[
"title"]);
75 $ilCtrl->setParameterByClass(
"illmpageobjectgui",
"obj_id",
77 $this->tpl->setVariable(
"HREF_PAGE",
78 $ilCtrl->getLinkTargetByClass(
"illmpageobjectgui",
"edit"));
80 include_once(
"./Modules/LearningModule/classes/class.ilLMPage.php");
81 $page_object =
new ilLMPage($a_set[
"obj_id"]);
82 $page_object->buildDom();
83 $int_links = $page_object->getInternalLinks();
85 foreach($int_links as $link)
87 $target = $link[
"Target"];
88 if (substr($target, 0, 4) ==
"il__")
92 $type = $link[
"Type"];
97 $this->tpl->setCurrentBlock(
"link");
98 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"pg"));
102 $add_str = ($lm_id != $this->lm_id)
105 $this->tpl->setVariable(
"TXT_LINK_TITLE",
110 $this->tpl->setVariable(
"TXT_MISSING",
111 "<b>".$lng->txt(
"cont_target_missing").
" [".
$target_id.
"]".
"</b>");
113 $this->tpl->parseCurrentBlock();
116 case "StructureObject":
117 $this->tpl->setCurrentBlock(
"link");
118 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"st"));
122 $add_str = ($lm_id != $this->lm_id)
125 $this->tpl->setVariable(
"TXT_LINK_TITLE",
130 $this->tpl->setVariable(
"TXT_MISSING",
131 "<b>".$lng->txt(
"cont_target_missing").
" [".
$target_id.
"]".
"</b>");
133 $this->tpl->parseCurrentBlock();
137 $this->tpl->setCurrentBlock(
"link");
138 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"cont_term"));
139 include_once(
"./Modules/Glossary/classes/class.ilGlossaryTerm.php");
142 $this->tpl->setVariable(
"TXT_LINK_TITLE",
147 $this->tpl->setVariable(
"TXT_MISSING",
148 "<b>".$lng->txt(
"cont_target_missing").
" [".
$target_id.
"]".
"</b>");
150 $this->tpl->parseCurrentBlock();
154 $this->tpl->setCurrentBlock(
"link");
155 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"mob"));
158 $this->tpl->setVariable(
"TXT_LINK_TITLE",
163 $this->tpl->setVariable(
"TXT_MISSING",
164 "<b>".$lng->txt(
"cont_target_missing").
" [".
$target_id.
"]".
"</b>");
166 $this->tpl->parseCurrentBlock();
169 case "RepositoryItem":
170 $this->tpl->setCurrentBlock(
"link");
171 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"cont_repository_item"));
176 $this->tpl->setVariable(
"TXT_LINK_TITLE",
178 $lng->txt((
"obj_".$obj_type))
183 $this->tpl->setVariable(
"TXT_MISSING",
184 "<b>".$lng->txt(
"cont_target_missing").
" [".
$target_id.
"]".
"</b>");
186 $this->tpl->parseCurrentBlock();
193 $type = $link[
"Type"];
198 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"pg"));
200 case "StructureObject":
201 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"st"));
204 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"cont_term"));
207 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"mob"));
209 case "RepositoryItem":
210 $this->tpl->setVariable(
"TXT_LINK_TYPE", $lng->txt(
"cont_repository_item"));
214 $this->tpl->setCurrentBlock(
"link");
215 $this->tpl->setVariable(
"TXT_MISSING",
216 "<b>".$lng->txt(
"cont_target_missing").
" [".$target.
"]".
"</b>");
217 $this->tpl->parseCurrentBlock();