6 require_once(
"./Services/Style/Content/classes/class.ilObjStyleSheet.php");
7 require_once (
"./Modules/Glossary/classes/class.ilGlossaryDefPageGUI.php");
45 $this->tabs_gui = $ilTabs;
47 $this->ctrl->saveParameter($this,
array(
"def"));
55 $next_class = $this->ctrl->getNextClass($this);
56 $cmd = $this->ctrl->getCmd();
59 $this->tpl->setCurrentBlock(
"ContentStyle");
60 $this->tpl->setVariable(
"LOCATION_CONTENT_STYLESHEET",
62 $this->tpl->parseCurrentBlock();
65 $this->tpl->setCurrentBlock(
"SyntaxStyle");
66 $this->tpl->setVariable(
"LOCATION_SYNTAX_STYLESHEET",
68 $this->tpl->parseCurrentBlock();
70 require_once (
"./Modules/Glossary/classes/class.ilGlossaryLocatorGUI.php");
72 $gloss_loc->setTerm($this->term);
73 $gloss_loc->setGlossary($this->glossary);
74 $gloss_loc->setDefinition($this->definition);
77 $this->tpl->setTitle($this->term->getTerm().
" - ".
78 $this->lng->txt(
"cont_definition").
" ".
79 $this->definition->getNr());
80 if ($this->ctrl->getNextClass() ==
"ilglossarydefpagegui")
88 case "ilglossarydefpagegui":
91 if ($ilCtrl->getCmd() ==
"edit" &&
92 $ilCtrl->getCmdClass() ==
"ilglossarydefpagegui")
98 $ilCtrl->getLinkTargetByClass(
"ilglossarytermgui",
"listUsages").
99 "'>".$lng->txt(
"glo_list_usages").
"</a>]";
106 if ($this->ctrl->getNextClass() ==
"ilglossarydefpagegui" 107 || $this->ctrl->getCmdClass() ==
"ileditclipboardgui")
109 $gloss_loc->display();
112 $this->ctrl->setReturnByClass(
"ilGlossaryDefPageGUI",
"edit");
113 $this->ctrl->setReturn($this,
"listDefinitions");
116 $this->definition->assignPageObject($page);
117 $page->addUpdateListener($this,
"saveShortText");
122 include_once(
"./Services/MetaData/classes/class.ilMD.php");
123 $md =
new ilMD($this->term_glossary->getId(), $this->definition->getId(),
"gdf");
125 if ($md_gen->getTitle() ==
"")
127 $md_gen->setTitle($this->term->getTerm());
131 $page_gui->activateMetaDataEditor($this->term_glossary,
"gdf", $this->definition->getId());
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");
139 $this->term_glossary->getStyleSheetId(),
"glo"));
140 $page_gui->setLocator($gloss_loc);
141 $page_gui->setIntLinkReturn($this->ctrl->getLinkTargetByClass(
"ilobjglossarygui",
"quickList",
143 $page_gui->setPageBackTitle($this->lng->txt(
"cont_definition"));
144 $page_gui->setLinkParams(
"ref_id=".
$_GET[
"ref_id"]);
145 $page_gui->setHeader($this->term->getTerm());
146 $page_gui->setFileDownloadLink(
"ilias.php?baseClass=ilGlossaryPresentationGUI&cmd=downloadFile&ref_id=".
$_GET[
"ref_id"]);
147 $page_gui->setPresentationTitle($this->term->getTerm());
148 $ret = $this->ctrl->forwardCommand($page_gui);
149 $tpl->setContent(
$ret);
154 $gloss_loc->display();
169 $this->tpl->getStandardTemplate();
170 $this->tpl->setTitle($a_header_title);
171 $this->displayLocator();
190 $this->tabs_gui->setBack2Target($this->lng->txt(
"glossary"),
191 $this->ctrl->getParentReturn($this));
194 $this->tabs_gui->setBackTarget($this->lng->txt(
"term"),
195 $this->ctrl->getLinkTargetByClass(
"ilglossarytermgui",
"editTerm"));
202 $this->definition->updateShortText();
setEditPreview($a_editpreview)
Set Display first Edit tab, then Preview tab, instead of Page and Edit.
getPageObject()
Get Page Object.
static getNumberOfUsages($a_term_id)
Get number of usages.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
GUI class for glossary term definition editor.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
static getEffectiveContentStyleId($a_style_id, $a_type="")
Get effective Style Id.
redirection script todo: (a better solution should control the processing via a xml file) ...
__construct()
Constructor public.
static getSyntaxStylePath()
get syntax style path
Create styles array
The data for the language used.
static _lookGlossaryID($term_id)
get glossary id form term id
Class ilGlossaryDefinition.
static getContentStylePath($a_style_id)
get content style path
Glossary definition page GUI class.
main_header($a_header_title)
output main header (title and locator)