6 require_once(
"./Services/Style/classes/class.ilObjStyleSheet.php");
7 require_once (
"./Services/COPage/classes/class.ilPageObjectGUI.php");
45 $this->ctrl->saveParameter($this, array(
"def"));
53 $next_class = $this->ctrl->getNextClass($this);
54 $cmd = $this->ctrl->getCmd();
57 $this->tpl->setCurrentBlock(
"ContentStyle");
58 $this->tpl->setVariable(
"LOCATION_CONTENT_STYLESHEET",
60 $this->tpl->parseCurrentBlock();
63 $this->tpl->setCurrentBlock(
"SyntaxStyle");
64 $this->tpl->setVariable(
"LOCATION_SYNTAX_STYLESHEET",
66 $this->tpl->parseCurrentBlock();
68 require_once (
"./Modules/Glossary/classes/class.ilGlossaryLocatorGUI.php");
70 $gloss_loc->setTerm($this->term);
71 $gloss_loc->setGlossary($this->glossary);
72 $gloss_loc->setDefinition($this->definition);
74 $this->tpl->getStandardTemplate();
75 $this->tpl->setTitle($this->term->getTerm().
" - ".
76 $this->lng->txt(
"cont_definition").
" ".
77 $this->definition->getNr());
78 if ($this->ctrl->getNextClass() ==
"ilpageobjectgui")
86 case "ilpageobjectgui":
89 if ($ilCtrl->getCmd() ==
"edit" &&
90 $ilCtrl->getCmdClass() ==
"ilpageobjectgui")
96 $ilCtrl->getLinkTargetByClass(
"ilglossarytermgui",
"listUsages").
97 "'>".$lng->txt(
"glo_list_usages").
"</a>]";
104 if ($this->ctrl->getNextClass() ==
"ilpageobjectgui"
105 || $this->ctrl->getCmdClass() ==
"ileditclipboardgui")
107 $gloss_loc->display();
110 $this->ctrl->setReturnByClass(
"ilPageObjectGUI",
"edit");
111 $this->ctrl->setReturn($this,
"listDefinitions");
114 $this->definition->assignPageObject($page);
115 $page->addUpdateListener($this,
"saveShortText");
120 include_once(
"./Services/MetaData/classes/class.ilMD.php");
121 $md =
new ilMD($this->glossary->getId(), $this->definition->getId(),
"gdf");
123 if ($md_gen->getTitle() ==
"")
125 $md_gen->setTitle($this->term->getTerm());
129 $page_gui->activateMetaDataEditor($this->glossary->getId(),
130 $this->definition->getId(),
"gdf");
133 $page_gui->setSourcecodeDownloadScript(
"ilias.php?baseClass=ilGlossaryPresentationGUI&ref_id=".
$_GET[
"ref_id"]);
134 $page_gui->setFullscreenLink(
"ilias.php?baseClass=ilGlossaryPresentationGUI&cmd=fullscreen&ref_id=".
$_GET[
"ref_id"]);
135 $page_gui->setTemplateTargetVar(
"ADM_CONTENT");
136 $page_gui->setOutputMode(
"edit");
137 $page_gui->setEnableKeywords(
true);
138 $page_gui->setStyleId($this->glossary->getStyleSheetId());
139 $page_gui->setLocator($gloss_loc);
140 $page_gui->setEnabledInternalLinks(
true);
141 $page_gui->setIntLinkHelpDefault(
"GlossaryItem",
$_GET[
"ref_id"]);
142 $page_gui->setIntLinkReturn($this->ctrl->getLinkTargetByClass(
"ilobjglossarygui",
"quickList",
144 $page_gui->setPageBackTitle($this->lng->txt(
"cont_definition"));
145 $page_gui->setLinkParams(
"ref_id=".
$_GET[
"ref_id"]);
146 $page_gui->setHeader($this->term->getTerm());
147 $page_gui->setFileDownloadLink(
"ilias.php?baseClass=ilGlossaryPresentationGUI&cmd=downloadFile&ref_id=".
$_GET[
"ref_id"]);
148 $page_gui->setPresentationTitle($this->term->getTerm());
149 $ret =& $this->ctrl->forwardCommand($page_gui);
150 $tpl->setContent(
$ret);
155 $gloss_loc->display();
170 $this->tpl->getStandardTemplate();
171 $this->tpl->setTitle($a_header_title);
172 $this->displayLocator();
193 $tabs_gui->setBack2Target($this->lng->txt(
"glossary"),
194 $this->ctrl->getParentReturn($this));
197 $tabs_gui->setBackTarget($this->lng->txt(
"term"),
198 $this->ctrl->getLinkTargetByClass(
"ilglossarytermgui",
"editTerm"));
205 $this->definition->updateShortText();