59 $this->glossary = $glo;
60 $this->export_dir = $exp_dir;
62 $this->target_dir = $exp_dir .
"/" .
$sub_dir;
64 $this->global_screen = $DIC->globalScreen();
65 $this->export_util = new \ILIAS\Services\Export\HTML\Util($exp_dir, $sub_dir);
66 $this->co_page_html_export = new \ilCOPageHTMLExport($this->target_dir);
69 $this->glo_gui = new \ilGlossaryPresentationGUI(
"html", $this->target_dir);
91 $this->export_util->exportSystemStyle();
92 $this->export_util->exportCOPageFiles($this->glossary->getStyleSheetId(),
"glo");
97 $this->export_util->exportResourceFiles();
99 $this->co_page_html_export->exportPageElements();
111 $zip_file = $this->glossary->getExportDirectory(
"html") .
"/" . $date .
"__" . IL_INST_ID .
"__" .
112 $this->glossary->getType() .
"_" . $this->glossary->getId() .
".zip";
125 $tabs = $DIC->tabs();
127 $tabs->clearTargets();
128 $tabs->clearSubTabs();
129 $tpl = new \ilGlobalPageTemplate($DIC->globalScreen(), $DIC->ui(), $DIC->http());
131 $this->co_page_html_export->getPreparedMainTemplate(
$tpl);
143 $this->global_screen->layout()->meta()->reset();
147 $this->global_screen->layout()->meta()->addCss($location_stylesheet);
148 $this->global_screen->layout()->meta()->addCss(
160 "term_id" => $term_id,
161 "ref_id" => $this->glossary->getRefId(),
165 $this->glo_gui->initByRequest($params);
167 $this->glo_gui->injectTemplate(
$tpl);
178 $tpl->setTitle($this->glossary->getTitle());
179 $content = $this->glo_gui->listTerms();
180 $file = $this->target_dir .
"/index.html";
183 $fp = @fopen($file,
"w+");
184 fwrite($fp, $content);
187 $terms = $this->glossary->getTermList();
188 foreach ($terms as $term) {
190 $content = $this->glo_gui->listDefinitions($this->glossary->getRefId(), $term[
"id"],
false);
191 $file = $this->target_dir .
"/term_" . $term[
"id"] .
".html";
194 $fp = @fopen($file,
"w+");
195 fwrite($fp, $content);
200 foreach ($defs as $def) {
201 $this->co_page_html_export->collectPageElements(
"gdf:pg", $def[
"id"],
"");
static getContentStylePath($a_style_id, $add_random=true, $add_token=true)
get content style path
static getDefinitionList($a_term_id)
static
initScreen(int $term_id)
Init page.
if(isset($_FILES['img_file']['size']) && $_FILES['img_file']['size'] > 0) $tpl
__construct(\ilObjGlossary $glo, string $exp_dir, string $sub_dir)
GlossaryHtmlExport constructor.
static getStyleSheetLocation($mode="output", $a_css_name="", $a_css_location="")
get full style sheet file name (path inclusive) of current user
initDirectories()
Initialize directories.
getInitialisedTemplate()
Get initialised template.
exportHTML()
export html package
Class ilGlobalPageTemplate.
static zip($a_dir, $a_file, $compress_content=false)
zips given directory/file into given zip.file
static makeDir($a_dir)
creates a new directory and inherits all filesystem permissions of the parent directory You may pass ...
exportHTMLGlossaryTerms()
static resetInitialState()
Reset initial state (for exports)
const HTML_EXPORT_RENDERING
static delDir($a_dir, $a_clean_only=false)
removes a dir and all its content (subdirs and files) recursively