73    public function __construct($a_data, $a_id = 0, $a_call_by_reference = 
true, $a_prepare_output = 
false)
 
   77        $this->lng = 
$DIC->language();
 
   78        $this->access = 
$DIC->access();
 
   79        $this->tabs = 
$DIC->tabs();
 
   80        $this->
error = $DIC[
"ilErr"];
 
   82        $this->
user = $DIC->user();
 
   83        $this->tpl = 
$DIC[
"tpl"];
 
   84        $this->toolbar = 
$DIC->toolbar();
 
   85        $this->rbacsystem = 
$DIC->rbac()->system();
 
   86        $this->tree = 
$DIC->repositoryTree();
 
   87        $this->plugin_admin = 
$DIC[
"ilPluginAdmin"];
 
   88        $this->
help = $DIC[
"ilHelp"];
 
   89        $this->locator = 
$DIC[
"ilLocator"];
 
   90        $this->db = 
$DIC->database();
 
   91        $this->log = 
$DIC[
"ilLog"];
 
   92        $this->
ui = $DIC->ui();
 
   94        $ilCtrl = 
$DIC->ctrl();
 
   95        $this->ctrl = $ilCtrl;
 
   96        $lng->loadLanguageModule(
"content");
 
   97        $lng->loadLanguageModule(
"obj");
 
  104            $baseclass = strtolower(
$_GET[
"baseClass"]);
 
  105            $next_class = strtolower($this->ctrl->getNextClass());
 
  108            if (!in_array($baseclass, [
"illmpresentationgui", 
"illmeditorgui"])) {
 
  111                if (in_array($next_class, [
"ilcommonactiondispatchergui"])) {
 
  134        if ($this->ctrl->getRedirectSource() == 
"ilinternallinkgui") {
 
  139        if ($this->ctrl->getCmdClass() == 
"ilinternallinkgui") {
 
  140            $this->ctrl->setReturn($this, 
"explorer");
 
  144        $next_class = $this->ctrl->getNextClass($this);
 
  147        if (
$_GET[
"to_props"] == 1) {
 
  148            $cmd = $this->ctrl->getCmd(
"properties");
 
  150            $cmd = $this->ctrl->getCmd(
"chapters");
 
  154        switch ($next_class) {
 
  155            case 'illtiproviderobjectsettinggui':
 
  158                $ilTabs->setTabActive(
"settings");
 
  162                $lti_gui->setCustomRolesForSelection(
$GLOBALS[
'DIC']->rbac()->review()->getLocalRoles($this->object->getRefId()));
 
  163                $lti_gui->offerLTIRolesForSelection(
true);
 
  164                $this->ctrl->forwardCommand($lti_gui);
 
  169            case "illearningprogressgui":
 
  172                $this->
setTabs(
"learning_progress");
 
  175                $this->ctrl->forwardCommand($new_gui);
 
  179            case 'ilobjectmetadatagui':
 
  180                if (!$ilAccess->checkAccess(
'write', 
'', $this->object->getRefId())) {
 
  181                    $ilErr->raiseError($this->lng->txt(
'permission_denied'), 
$ilErr->WARNING);
 
  189                $md_gui->addMDObserver($this->
object, 
'MDUpdateListener', 
'Educational'); 
 
  190                $md_gui->addMDObserver($this->
object, 
'MDUpdateListener', 
'General');
 
  191                $this->ctrl->forwardCommand($md_gui);
 
  194            case "ilobjstylesheetgui":
 
  196                $this->ctrl->setReturn($this, 
"editStyleProperties");
 
  197                $style_gui = 
new ilObjStyleSheetGUI(
"", $this->object->getStyleSheetId(), 
false, 
false);
 
  198                $style_gui->omitLocator();
 
  199                if ($cmd == 
"create" || 
$_GET[
"new_type"] == 
"sty") {
 
  200                    $style_gui->setCreationMode(
true);
 
  202                $ret = $this->ctrl->forwardCommand($style_gui);
 
  204                if ($cmd == 
"save" || $cmd == 
"copyStyle" || $cmd == 
"importStyle") {
 
  206                    $this->
object->setStyleSheetId($style_id);
 
  207                    $this->
object->update();
 
  208                    $this->ctrl->redirectByClass(
"ilobjstylesheetgui", 
"edit");
 
  212            case "illmpageobjectgui":
 
  214                $ilTabs->setBackTarget(
 
  215                    $lng->txt(
"learning module"),
 
  216                    $ilCtrl->getLinkTarget($this, 
"chapters")
 
  218                $this->ctrl->saveParameter($this, array(
"obj_id"));
 
  220                $this->ctrl->setReturn($this, 
"chapters");
 
  223                if (
$_GET[
"obj_id"] != 
"") {
 
  225                    $pg_gui->setLMPageObject($obj);
 
  227                $ret = $this->ctrl->forwardCommand($pg_gui);
 
  230            case "ilstructureobjectgui":
 
  231                $ilTabs->setBackTarget(
 
  232                    $lng->txt(
"learning module"),
 
  233                    $ilCtrl->getLinkTarget($this, 
"chapters")
 
  236                $this->ctrl->saveParameter($this, array(
"obj_id"));
 
  238                $this->ctrl->setReturn($this, 
"chapters");
 
  240                if (
$_GET[
"obj_id"] != 
"") {
 
  242                    $st_gui->setStructureObject($obj);
 
  244                $ret = $this->ctrl->forwardCommand($st_gui);
 
  245                if ($cmd == 
"save" || $cmd == 
"cancel") {
 
  246                    if (
$_GET[
"obj_id"] == 
"") {
 
  247                        $this->ctrl->redirect($this, 
"chapters");
 
  249                        $this->ctrl->setCmd(
"subchap");
 
  255            case 'ilpermissiongui':
 
  256                if (strtolower(
$_GET[
"baseClass"]) == 
"iladministrationgui") {
 
  264                $ret = $this->ctrl->forwardCommand($perm_gui);
 
  268            case 'ilinfoscreengui':
 
  273                $info->enablePrivateNotes();
 
  274                $info->enableLearningProgress();
 
  277                if ($ilAccess->checkAccess(
"write", 
"", 
$_GET[
"ref_id"])) {
 
  278                    $info->enableNewsEditing();
 
  279                    $info->setBlockProperty(
"news", 
"settings", 
true);
 
  283                $info->addMetaDataSections(
 
  284                    $this->object->getId(),
 
  286                    $this->object->getType()
 
  289                $ret = $this->ctrl->forwardCommand($info);
 
  294                $exp_gui->addFormat(
"xml");
 
  296                if ($ot->getContentActivated()) {
 
  297                    $exp_gui->addFormat(
"xml_master", 
"XML (" . 
$lng->txt(
"cont_master_language_only") . 
")", $this, 
"export");
 
  298                    $exp_gui->addFormat(
"xml_masternomedia", 
"XML (" . 
$lng->txt(
"cont_master_language_only_no_media") . 
")", $this, 
"export");
 
  300                    $lng->loadLanguageModule(
"meta");
 
  301                    $langs = $ot->getLanguages();
 
  302                    foreach ($langs as $l => $ldata) {
 
  303                        $exp_gui->addFormat(
"html_" . $l, 
"HTML (" . 
$lng->txt(
"meta_l_" . $l) . 
")", $this, 
"exportHTML");
 
  305                    $exp_gui->addFormat(
"html_all", 
"HTML (" . 
$lng->txt(
"cont_all_languages") . 
")", $this, 
"exportHTML");
 
  307                    $exp_gui->addFormat(
"html", 
"", $this, 
"exportHTML");
 
  310                $exp_gui->addFormat(
"scorm", 
"", $this, 
"exportSCORM");
 
  311                $exp_gui->addCustomColumn(
 
  312                    $lng->txt(
"cont_public_access"),
 
  314                    "getPublicAccessColValue" 
  316                $exp_gui->addCustomMultiCommand(
 
  317                    $lng->txt(
"cont_public_access"),
 
  321                $ret = $this->ctrl->forwardCommand($exp_gui);
 
  328            case 'ilobjecttranslationgui':
 
  334                $transgui->setTitleDescrOnlyMode(
false);
 
  335                $this->ctrl->forwardCommand($transgui);
 
  339            case "ilcommonactiondispatchergui":
 
  342                $this->ctrl->forwardCommand($gui);
 
  345            case 'ilobjectcopygui':
 
  349                $this->ctrl->forwardCommand($cp);
 
  352            case "ilmobmultisrtuploadgui":
 
  358                $this->ctrl->forwardCommand($gui);
 
  361            case "illmimportgui":
 
  367                $this->ctrl->forwardCommand($gui);
 
  370            case "illmeditshorttitlesgui":
 
  376                $this->ctrl->forwardCommand($gui);
 
  380                $new_type = 
$_POST[
"new_type"]
 
  385                if ($cmd == 
"create" &&
 
  386                    !in_array($new_type, array(
"lm"))) {
 
  390                            $this->ctrl->setCmdClass(
"ilLMPageObjectGUI");
 
  396                            $this->ctrl->setCmdClass(
"ilStructureObjectGUI");
 
  403                        in_array($new_type, array(
"lm"))) {
 
  409                        $ret = $this->$cmd();
 
  413                        $ret = $this->$cmd();
 
  423        return array(
"ilLMPageObjectGUI", 
"ilStructureObjectGUI",
"ilObjStyleSheetGUI");
 
  433        $lng->loadLanguageModule(
"style");
 
  441        if ($this->object->getType() == 
"lm") {
 
  444            $ecs->addSettingsToForm($this->form, 
'lm');
 
  447        $this->tpl->setContent($this->form->getHTML());
 
  465        $ti->setRequired(
true);
 
  466        $this->form->addItem($ti);
 
  470        $this->form->addItem($ta);
 
  472        $lng->loadLanguageModule(
"rep");
 
  474        $section->setTitle($this->lng->txt(
'rep_activation_availability'));
 
  479        $this->form->addItem($online);
 
  483        $section->setTitle($this->lng->txt(
'cont_presentation'));
 
  487        $obj_service->commonSettings()->legacyForm($this->form, $this->
object)->addTileImage();
 
  502        $option = array(
"st_title" => $this->lng->txt(
"cont_st_title"),
 
  503            "pg_title" => $this->lng->txt(
"cont_pg_title"),
 
  504            "none" => $this->lng->txt(
"cont_none"));
 
  505        $page_header->setOptions($option);
 
  506        $this->form->addItem($page_header);
 
  510        $this->form->addItem($chap_num);
 
  514        $option = array(
"chapters" => $this->lng->txt(
"cont_chapters_only"),
 
  515            "pages" => $this->lng->txt(
"cont_chapters_and_pages"));
 
  516        $toc_mode->setOptions($option);
 
  517        $this->form->addItem($toc_mode);
 
  521        $progr_icons->setInfo($this->lng->txt(
"cont_progress_icons_info"));
 
  522        $this->form->addItem($progr_icons);
 
  526        $section->setTitle($this->lng->txt(
'cont_self_assessment'));
 
  532        $op1 = 
new ilRadioOption(
$lng->txt(
"cont_tries_reset_on_visit"), 0, 
$lng->txt(
"cont_tries_reset_on_visit_info"));
 
  533        $radg->addOption($op1);
 
  535        $radg->addOption($op2);
 
  536        $this->form->addItem($radg);
 
  540        $qfeed->setInfo($this->lng->txt(
"cont_restrict_forw_nav_info"));
 
  541        $this->form->addItem($qfeed);
 
  545        $not->setInfo($this->lng->txt(
"cont_notify_on_blocked_users_info"));
 
  546        $qfeed->addSubItem($not);
 
  550        $qfeed->setInfo($this->lng->txt(
"cont_disable_def_feedback_info"));
 
  551        $this->form->addItem($qfeed);
 
  555        $section->setTitle($this->lng->txt(
'obj_features'));
 
  560            $this->lng->loadLanguageModule(
"notes");
 
  562            $pub_nodes->setInfo($this->lng->txt(
"cont_lm_comments_desc"));
 
  563            $this->form->addItem($pub_nodes);
 
  568        $com->setInfo($this->lng->txt(
"enable_hist_user_comments_desc"));
 
  569        $this->form->addItem($com);
 
  572        $this->lng->loadLanguageModule(
'rating');
 
  574        $rate->setInfo($this->lng->txt(
'rating_activate_rating_info'));
 
  575        $this->form->addItem($rate);
 
  576        $ratep = 
new ilCheckboxInputGUI($this->lng->txt(
'lm_activate_rating'), 
'rating_pages');
 
  577        $this->form->addItem($ratep);
 
  579        $this->form->setTitle(
$lng->txt(
"cont_lm_properties"));
 
  580        $this->form->addCommandButton(
"saveProperties", 
$lng->txt(
"save"));
 
  581        $this->form->setFormAction($ilCtrl->getFormAction($this));
 
  593        $title = $this->
object->getTitle();
 
  594        $description = $this->
object->getLongDescription();
 
  596        if ($ot->getContentActivated()) {
 
  597            $title = $ot->getDefaultTitle();
 
  598            $description = $ot->getDefaultDescription();
 
  601        $values[
"title"] = $title;
 
  602        $values[
"description"] = $description;
 
  603        if (!$this->object->getOfflineStatus()) {
 
  604            $values[
"cobj_online"] = 
true;
 
  607        $values[
"lm_pg_header"] = $this->
object->getPageHeader();
 
  608        if ($this->object->isActiveNumbering()) {
 
  609            $values[
"cobj_act_number"] = 
true;
 
  611        $values[
"toc_mode"] = $this->
object->getTOCMode();
 
  612        if ($this->object->publicNotes()) {
 
  613            $values[
"cobj_pub_notes"] = 
true;
 
  615        if ($this->object->cleanFrames()) {
 
  616            $values[
"cobj_clean_frames"] = 
true;
 
  618        if ($this->object->isActiveHistoryUserComments()) {
 
  619            $values[
"cobj_user_comments"] = 
true;
 
  622        $values[
"rating"] = $this->
object->hasRating();
 
  623        $values[
"rating_pages"] = $this->
object->hasRatingPages();
 
  624        $values[
"disable_def_feedback"] = $this->
object->getDisableDefaultFeedback();
 
  625        $values[
"progr_icons"] = $this->
object->getProgressIcons();
 
  626        $values[
"store_tries"] = $this->
object->getStoreTries();
 
  627        $values[
"restrict_forw_nav"] = $this->
object->getRestrictForwardNavigation();
 
  632            $this->object->getId()
 
  635        $this->form->setValuesByArray($values);
 
  650        if ($this->form->checkInput()) {
 
  652            if ($ot->getContentActivated()) {
 
  653                $ot->setDefaultTitle(
$_POST[
'title']);
 
  654                $ot->setDefaultDescription(
$_POST[
'description']);
 
  658            $this->
object->setTitle(
$_POST[
'title']);
 
  659            $this->
object->setDescription(
$_POST[
'description']);
 
  661            $this->
object->setPageHeader(
$_POST[
"lm_pg_header"]);
 
  662            $this->
object->setTOCMode(
$_POST[
"toc_mode"]);
 
  663            $this->
object->setOfflineStatus(!(
$_POST[
'cobj_online']));
 
  664            $this->
object->setActiveNumbering(
$_POST[
"cobj_act_number"]);
 
  665            $this->
object->setCleanFrames(
$_POST[
"cobj_clean_frames"]);
 
  667                $this->
object->setPublicNotes(
$_POST[
"cobj_pub_notes"]);
 
  669            $this->
object->setHistoryUserComments(
$_POST[
"cobj_user_comments"]);
 
  671            $this->
object->setRating(
$_POST[
"rating"]);
 
  672            $this->
object->setRatingPages(
$_POST[
"rating_pages"]);
 
  673            $this->
object->setDisableDefaultFeedback((
int) 
$_POST[
"disable_def_feedback"]);
 
  674            $this->
object->setProgressIcons((
int) $_POST[
"progr_icons"]);
 
  677            if (
$_POST[
"restrict_forw_nav"] && !
$_POST[
"store_tries"]) {
 
  678                $_POST[
"store_tries"] = 1;
 
  679                $add_info = 
"</br>" . 
$lng->txt(
"cont_automatically_set_store_tries");
 
  680                $add_info = str_replace(
"$1", 
$lng->txt(
"cont_tries_store"), $add_info);
 
  681                $add_info = str_replace(
"$2", 
$lng->txt(
"cont_restrict_forw_nav"), $add_info);
 
  684            $this->
object->setStoreTries((
int) $_POST[
"store_tries"]);
 
  685            $this->
object->setRestrictForwardNavigation((
int) $_POST[
"restrict_forw_nav"]);
 
  686            $this->
object->updateProperties();
 
  687            $this->
object->update();
 
  690            $obj_service->commonSettings()->legacyForm($this->form, $this->
object)->saveTileImage();
 
  695                $this->object->getId(),
 
  696                (
bool) $this->form->getInput(
"notification_blocked_users")
 
  700            if ($this->object->getType() == 
'lm') {
 
  703                if ($ecs->handleSettingsUpdate()) {
 
  712            ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified") . $add_info, 
true);
 
  713            $this->ctrl->redirect($this, 
"properties");
 
  715            $lng->loadLanguageModule(
"style");
 
  719            $this->form->setValuesByPost();
 
  720            $this->tpl->setContent($this->form->getHTML());
 
  732        $tpl->setContent($this->form->getHTML());
 
  745        $lng->loadLanguageModule(
"style");
 
  747        $ilTabs->setTabActive(
"settings");
 
  752        $fixed_style = 
$ilSetting->get(
"fixed_content_style_id");
 
  753        $def_style = 
$ilSetting->get(
"default_content_style_id");
 
  754        $style_id = $this->
object->getStyleSheetId();
 
  756        if ($fixed_style > 0) {
 
  759                $this->lng->txt(
"global_fixed") . 
")");
 
  760            $this->form->addItem($st);
 
  768            if ($def_style > 0) {
 
  771                $st_styles[0] = $this->lng->txt(
"default");
 
  780                    $this->form->addItem($st);
 
  783                    $this->form->addCommandButton(
 
  785                        $lng->txt(
"cont_edit_style")
 
  787                    $this->form->addCommandButton(
 
  789                        $lng->txt(
"cont_delete_style")
 
  796                $style_sel->setOptions($st_styles);
 
  797                $style_sel->setValue($style_id);
 
  798                $this->form->addItem($style_sel);
 
  799                $this->form->addCommandButton(
 
  803                $this->form->addCommandButton(
 
  805                    $lng->txt(
"sty_create_ind_style")
 
  809        $this->form->setTitle(
$lng->txt(
"cont_style"));
 
  810        $this->form->setFormAction($ilCtrl->getFormAction($this));
 
  820        $ilCtrl->redirectByClass(
"ilobjstylesheetgui", 
"create");
 
  830        $ilCtrl->redirectByClass(
"ilobjstylesheetgui", 
"edit");
 
  840        $ilCtrl->redirectByClass(
"ilobjstylesheetgui", 
"delete");
 
  850        if (
$ilSetting->get(
"fixed_content_style_id") <= 0 &&
 
  852            || $this->object->getStyleSheetId() == 0)) {
 
  854            $this->
object->update();
 
  855            ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified"), 
true);
 
  857        $this->ctrl->redirect($this, 
"editStyleProperties");
 
  872        $menu->setChecked($this->object->isActiveLMMenu());
 
  873        $form->addItem($menu);
 
  882        $print = 
new ilCheckboxInputGUI($this->lng->txt(
"cont_print_view"), 
"cobj_act_print");
 
  883        $print->setChecked($this->object->isActivePrintView());
 
  884        $form->addItem($print);
 
  887        $glo = 
new ilCheckboxInputGUI($this->lng->txt(
"cont_print_view_pre_glo"), 
"cobj_act_print_prev_glo");
 
  888        $glo->setChecked($this->object->isActivePreventGlossaryAppendix());
 
  889        $print->addSubItem($glo);
 
  892        $hhfp = 
new ilCheckboxInputGUI($this->lng->txt(
"cont_hide_head_foot_print"), 
"hide_head_foot_print");
 
  893        $hhfp->setChecked($this->object->getHideHeaderFooterPrint());
 
  894        $print->addSubItem($hhfp);
 
  897        $no_download_file_available =
 
  898            " " . 
$lng->txt(
"cont_no_download_file_available") .
 
  899            " <a href='" . $ilCtrl->getLinkTargetByClass(
"ilexportgui", 
"") . 
"'>" . 
$lng->txt(
"change") . 
"</a>";
 
  900        $types = array(
"xml", 
"html", 
"scorm");
 
  901        foreach ($types as 
$type) {
 
  902            if ($this->object->getPublicExportFile(
$type) != 
"") {
 
  903                if (is_file($this->object->getExportDirectory(
$type) . 
"/" .
 
  904                    $this->object->getPublicExportFile(
$type))) {
 
  905                    $no_download_file_available = 
"";
 
  909        $dl = 
new ilCheckboxInputGUI($this->lng->txt(
"cont_downloads"), 
"cobj_act_downloads");
 
  910        $dl->setInfo($this->lng->txt(
"cont_downloads_desc") . $no_download_file_available);
 
  911        $dl->setChecked($this->object->isActiveDownloads());
 
  915        $pdl = 
new ilCheckboxInputGUI($this->lng->txt(
"cont_downloads_public_desc"), 
"cobj_act_downloads_public");
 
  916        $pdl->setChecked($this->object->isActiveDownloadsPublic());
 
  917        $dl->addSubItem($pdl);
 
  919        $form->addCommandButton(
"saveMenuProperties", 
$lng->txt(
"save"));
 
  921        $form->setTitle(
$lng->txt(
"cont_lm_menu"));
 
  922        $form->setFormAction($ilCtrl->getFormAction($this));
 
  938        $lng->loadLanguageModule(
"style");
 
  940        $ilTabs->setTabActive(
"settings");
 
  943        $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
 
  944        $ilToolbar->addFormButton($this->lng->txt(
"add_menu_entry"), 
"addMenuEntry");
 
  945        $ilToolbar->setCloseFormTag(
false);
 
  948        $form->setOpenTag(
false);
 
  949        $form->setCloseTag(
false);
 
  952        $entries = $this->lmme_obj->getMenuEntries();
 
  954        $table->setOpenFormTag(
false);
 
  956        $tpl->setContent($form->getHTML() . 
"<br />" . $table->getHTML());
 
  964        $this->
object->setActiveLMMenu((
int) 
$_POST[
"cobj_act_lm_menu"]);
 
  966        $this->
object->setActivePrintView((
int) $_POST[
"cobj_act_print"]);
 
  967        $this->
object->setActivePreventGlossaryAppendix((
int) $_POST[
"cobj_act_print_prev_glo"]);
 
  968        $this->
object->setHideHeaderFooterPrint((
int) $_POST[
"hide_head_foot_print"]);
 
  969        $this->
object->setActiveDownloads((
int) $_POST[
"cobj_act_downloads"]);
 
  970        $this->
object->setActiveDownloadsPublic((
int) $_POST[
"cobj_act_downloads_public"]);
 
  971        $this->
object->updateProperties();
 
  975        $this->lmme_obj->updateActiveStatus(
$_POST[
"menu_entries"]);
 
  977        ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified"), 
true);
 
  978        $this->ctrl->redirect($this, 
"editMenuProperties");
 
  988        $gui_class = 
"ilobjlearningmodulegui";
 
  990        $ilCtrl->setParameterByClass($gui_class, 
"active_node", 
$_GET[
"active_node"]);
 
  992        $this->tpl = 
new ilTemplate(
"tpl.main.html", 
true, 
true);
 
  996        $this->tpl->addBlockFile(
"CONTENT", 
"content", 
"tpl.explorer.html");
 
  999        $exp = 
new ilLMEditorExplorer(
 
 1000            $this->ctrl->getLinkTarget($this, 
"view"),
 
 1005        $exp->setTargetGet(
"obj_id");
 
 1006        $exp->setExpandTarget($this->ctrl->getLinkTarget($this, 
"explorer"));
 
 1008        if (
$_GET[
"lmmovecopy"] == 
"1") {
 
 1013        if (
$_GET[
"lmexpand"] == 
"") {
 
 1014            $mtree = 
new ilTree($this->object->getId());
 
 1015            $mtree->setTableNames(
'lm_tree', 
'lm_data');
 
 1016            $mtree->setTreeTablePK(
"lm_id");
 
 1017            $expanded = $mtree->readRootId();
 
 1019            $expanded = 
$_GET[
"lmexpand"];
 
 1021        if (
$_GET[
"active_node"] != 
"") {
 
 1022            $path = $this->lm_tree->getPathId(
$_GET[
"active_node"]);
 
 1023            $exp->setForceOpenPath($path);
 
 1025            $exp->highlightNode(
$_GET[
"active_node"]);
 
 1027        $exp->setExpand($expanded);
 
 1031        $output = $exp->getOutput();
 
 1034        if ($ilCtrl->isAsynch()) {
 
 1039        $this->tpl->setCurrentBlock(
"content");
 
 1040        $this->tpl->setVariable(
"TXT_EXPLORER_HEADER", $this->lng->txt(
"cont_chap_and_pages"));
 
 1041        $this->tpl->setVariable(
"EXP_REFRESH", $this->lng->txt(
"refresh"));
 
 1042        $this->tpl->setVariable(
"EXPLORER", $output);
 
 1043        $this->ctrl->setParameter($this, 
"lmexpand", 
$_GET[
"lmexpand"]);
 
 1044        $this->tpl->setVariable(
"ACTION", $this->ctrl->getLinkTarget($this, 
"explorer"));
 
 1045        $this->tpl->parseCurrentBlock();
 
 1046        $this->tpl->printToStdout(
false);
 
 1055        $popup = 
new ilWysiwygUtil();
 
 1056        $popup->show(
$_GET[
"ptype"]);
 
 1067        $this->
object->executeDragDrop(
 
 1068            $_POST[
"il_hform_source_id"],
 
 1069            $_POST[
"il_hform_target_id"],
 
 1071            $_POST[
"il_hform_as_subitem"]
 
 1073        $ilCtrl->redirect($this, 
"chapters");
 
 1086        $a_new_object->setCleanFrames(
true);
 
 1090        $a_new_object->createLMTree();
 
 1093        $a_new_object->addFirstChapterAndPage();
 
 1096        ilUtil::sendSuccess($this->lng->txt($this->type . 
"_added"), 
true);
 
 1098            "&baseClass=ilLMEditorGUI");
 
 1106        $form = parent::initImportForm($a_new_type);
 
 1110        $cb->setInfo($this->lng->txt(
""));
 
 1111        $form->addItem($cb);
 
 1153            parent::importFileObject(
null, 
false);
 
 1157            $no_manifest = 
true;
 
 1161            $form->setValuesByPost();
 
 1162            $tpl->setContent($form->getHtml());
 
 1166        if (!$no_manifest) {
 
 1173            $ilErr->raiseError($this->lng->txt(
"no_create_permission"), 
$ilErr->MESSAGE);
 
 1177        if ($form->checkInput()) {
 
 1180            $newObj->setType(
$_GET[
"new_type"]);
 
 1181            $newObj->setTitle($_FILES[
"importfile"][
"name"]);
 
 1182            $newObj->setDescription(
"");
 
 1183            $newObj->create(
true);
 
 1184            $newObj->createReference();
 
 1185            $newObj->putInTree(
$_GET[
"ref_id"]);
 
 1186            $newObj->setPermissions(
$_GET[
"ref_id"]);
 
 1189            $newObj->createLMTree();
 
 1192            $mess = $newObj->importFromDirectory($this->tmp_import_dir, 
$_POST[
"validate"]);
 
 1195                ilUtil::sendSuccess($this->lng->txt($this->type . 
"_added"), 
true);
 
 1197                    "&baseClass=ilLMEditorGUI");
 
 1199                $link = 
'<a href="' . 
"ilias.php?ref_id=" . $newObj->getRefId() .
 
 1200                    "&baseClass=ilLMEditorGUI" . 
'" target="_top">' . $this->lng->txt(
"btn_next") . 
'</a>';
 
 1201                $tpl->setContent(
"<br />" . $link . 
"<br /><br />" . $mess . $link);
 
 1204            $form->setValuesByPost();
 
 1205            $tpl->setContent($form->getHtml());
 
 1220        $ilCtrl->setParameter($this, 
"backcmd", 
"chapters");
 
 1223        $form_gui->setFormAction($ilCtrl->getFormAction($this));
 
 1224        $form_gui->setTitle($this->object->getTitle());
 
 1226        $form_gui->setTree($this->lm_tree);
 
 1227        $form_gui->setMaxDepth(0);
 
 1228        $form_gui->setCurrentTopNodeId($this->tree->getRootId());
 
 1229        $form_gui->addMultiCommand(
$lng->txt(
"delete"), 
"delete");
 
 1230        $form_gui->addMultiCommand(
$lng->txt(
"cut"), 
"cutItems");
 
 1231        $form_gui->addMultiCommand(
$lng->txt(
"copy"), 
"copyItems");
 
 1232        if ($this->object->getLayoutPerPage()) {
 
 1233            $form_gui->addMultiCommand(
$lng->txt(
"cont_set_layout"), 
"setPageLayoutInHierarchy");
 
 1236        $form_gui->addCommand(
$lng->txt(
"cont_save_all_titles"), 
"saveAllTitles");
 
 1237        $up_gui = 
"ilobjlearningmodulegui";
 
 1239        $ctpl = 
new ilTemplate(
"tpl.chap_and_pages.html", 
true, 
true, 
"Modules/LearningModule");
 
 1240        $ctpl->setVariable(
"HIERARCHY_FORM", $form_gui->getHTML());
 
 1241        $ilCtrl->setParameter($this, 
"obj_id", 
"");
 
 1245        $this->tpl->setContent($ml_head . $ctpl->get());
 
 1259        $ilCtrl = 
$DIC->ctrl();
 
 1263        if ($ot->getContentActivated()) {
 
 1264            $ilCtrl->setParameter($a_gui_class, 
"lang_switch_mode", $a_mode);
 
 1265            $lng->loadLanguageModule(
"meta");
 
 1269            $ml_head = $ml_gui->getMultiLangInfo(
$_GET[
"transl"]);
 
 1273            $list->setListTitle(
$lng->txt(
"actions"));
 
 1274            $list->setId(
"copage_act");
 
 1276            if (!in_array(
$_GET[
"transl"], array(
"", 
"-"))) {
 
 1277                $l = $ot->getMasterLanguage();
 
 1279                    $lng->txt(
"cont_edit_language_version") . 
": " .
 
 1280                    $lng->txt(
"meta_l_" . $l),
 
 1282                    $ilCtrl->getLinkTarget($a_gui_class, 
"editMasterLanguage")
 
 1287            foreach ($ot->getLanguages() as $al => 
$lang) {
 
 1288                if (
$_GET[
"transl"] != $al &&
 
 1289                    $al != $ot->getMasterLanguage()) {
 
 1290                    $ilCtrl->setParameter($a_gui_class, 
"totransl", $al);
 
 1292                        $lng->txt(
"cont_edit_language_version") . 
": " .
 
 1293                        $lng->txt(
"meta_l_" . $al),
 
 1295                        $ilCtrl->getLinkTarget($a_gui_class, 
"switchToLanguage")
 
 1297                    $ilCtrl->setParameter($a_gui_class, 
"totransl", 
$_GET[
"totransl"]);
 
 1303                $ml_head = 
'<div class="ilFloatLeft">' . $ml_head . 
'</div><div style="margin: 5px 0;" class="small ilRight">' . $list->getHTML() . 
"</div>";
 
 1305            $ilCtrl->setParameter($a_gui_class, 
"lang_switch_mode", 
"");
 
 1325        $ilCtrl->setParameter($this, 
"backcmd", 
"pages");
 
 1326        $ilCtrl->setParameterByClass(
"illmpageobjectgui", 
"new_type", 
"pg");
 
 1327        $ilToolbar->addButton(
 
 1328            $lng->txt(
"pg_add"),
 
 1329            $ilCtrl->getLinkTargetByClass(
"illmpageobjectgui", 
"create")
 
 1331        $ilCtrl->setParameterByClass(
"illmpageobjectgui", 
"new_type", 
"");
 
 1334        $tpl->setContent($t->getHTML());
 
 1350            $this->object->getId(),
 
 1351            $this->object->getType()
 
 1354        $tpl->setContent($table_gui->getHTML());
 
 1367        $ilToolbar->addButton(
 
 1368            $this->lng->txt(
"cont_fix_tree"),
 
 1369            $this->ctrl->getLinkTarget($this, 
"fixTreeConfirm")
 
 1378        if (is_array(
$_POST[
"id"])) {
 
 1379            foreach (
$_POST[
"id"] as $id) {
 
 1385        $this->ctrl->redirect($this, 
"pages");
 
 1396            $ilErr->raiseError($this->lng->txt(
"no_page_in_clipboard"), 
$ilErr->MESSAGE);
 
 1406                == $this->object->getID()) {
 
 1408                $new_page = $lm_page->copy();
 
 1409                $id = $new_page->getId();
 
 1415                $copied_nodes = array();
 
 1416                $new_page = $lm_page->copyToOtherContObject($this->
object, $copied_nodes);
 
 1417                $id = $new_page->getId();
 
 1426                != $this->object->getID()) {
 
 1430                $lm_page->setLMId($this->object->getID());
 
 1432                $page = $lm_page->getPageObject();
 
 1434                $page->setParentId($this->object->getID());
 
 1441        $this->ctrl->redirect($this, 
"pages");
 
 1451        if (!isset(
$_POST[
"id"])) {
 
 1452            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1459        ilUtil::sendInfo($this->lng->txt(
"cont_selected_items_have_been_copied"), 
true);
 
 1461        $this->ctrl->redirect($this, 
"pages");
 
 1471    public function delete($a_parent_subobj_id = 0)
 
 1475        if (!isset(
$_POST[
"id"])) {
 
 1476            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1480            $ilErr->raiseError($this->lng->txt(
"cont_select_item"), 
$ilErr->MESSAGE);
 
 1483        if ($a_parent_subobj_id == 0) {
 
 1487        if ($a_parent_subobj_id != 0) {
 
 1488            $this->ctrl->setParameterByClass(
"ilStructureObjectGUI", 
"backcmd", 
$_GET[
"backcmd"]);
 
 1489            $this->ctrl->setParameterByClass(
"ilStructureObjectGUI", 
"obj_id", $a_parent_subobj_id);
 
 1490            $form_action = $this->ctrl->getFormActionByClass(
"ilStructureObjectGUI");
 
 1492            $this->ctrl->setParameter($this, 
"backcmd", 
$_GET[
"backcmd"]);
 
 1493            $form_action = $this->ctrl->getFormAction($this);
 
 1498        $cgui->setFormAction($form_action);
 
 1499        $cgui->setHeaderText($this->lng->txt(
"info_delete_sure"));
 
 1500        $cgui->setCancel($this->lng->txt(
"cancel"), 
"cancelDelete");
 
 1501        $cgui->setConfirm($this->lng->txt(
"confirm"), 
"confirmedDelete");
 
 1503        foreach (
$_POST[
"id"] as $id) {
 
 1507                    " " . $obj->getTitle();
 
 1509                $cgui->addItem(
"id[]", $id, $caption);
 
 1513        $this->tpl->setContent($cgui->getHTML());
 
 1521        $this->ctrl->redirect($this, 
$_GET[
"backcmd"]);
 
 1536        $tree->setTableNames(
'lm_tree', 
'lm_data');
 
 1537        $tree->setTreeTablePK(
"lm_id");
 
 1541            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1545        foreach (
$_POST[
"id"] as $id) {
 
 1548                $node_data = 
$tree->getNodeData($id);
 
 1549                if (is_object($obj)) {
 
 1550                    $obj->setLMId($this->object->getId());
 
 1553                        $this->object->getId(),
 
 1554                        "delete_" . $obj->getType(),
 
 1556                        $this->object->getType()
 
 1561                if (
$tree->isInTree($id)) {
 
 1562                    $tree->deleteTree($node_data);
 
 1568        $this->
object->checkTree();
 
 1571        ilUtil::sendSuccess($this->lng->txt(
"info_deleted"), 
true);
 
 1573        if ($a_parent_subobj_id == 0) {
 
 1574            $this->ctrl->redirect($this, 
$_GET[
"backcmd"]);
 
 1590        $tmpPath = $this->lm_tree->getPathFull($a_endnode_id, $a_startnode_id);
 
 1593        for (
$i = 1; 
$i < (count($tmpPath) - 1); 
$i++) {
 
 1598            $path .= $tmpPath[
$i][
"title"];
 
 1617        $notoperations = array();
 
 1619        $operations = array();
 
 1622            foreach (
$d as $row) {
 
 1623                if (!in_array($row[
"name"], $notoperations)) {
 
 1624                    $operations[] = $row;
 
 1629        if (count($operations) > 0) {
 
 1630            foreach ($operations as $val) {
 
 1631                $this->tpl->setCurrentBlock(
"operation_btn");
 
 1632                $this->tpl->setVariable(
"BTN_NAME", $val[
"name"]);
 
 1633                $this->tpl->setVariable(
"BTN_VALUE", $this->lng->txt($val[
"lng"]));
 
 1634                $this->tpl->parseCurrentBlock();
 
 1637            $this->tpl->setCurrentBlock(
"operation");
 
 1639            $this->tpl->parseCurrentBlock();
 
 1648        if (strtolower(
$_GET[
"baseClass"]) == 
"iladministrationgui") {
 
 1650            parent::viewObject();
 
 1664        if (!isset(
$_POST[
"id"])) {
 
 1665            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1667        if (count(
$_POST[
"id"]) > 1) {
 
 1668            $ilErr->raiseError($this->lng->txt(
"cont_select_max_one_item"), 
$ilErr->MESSAGE);
 
 1672            $ilErr->raiseError($this->lng->txt(
"cont_select_item"), 
$ilErr->MESSAGE);
 
 1680        if ($a_parent_subobj_id == 0) {
 
 1681            $this->ctrl->redirect($this, 
"chapters");
 
 1709        if (!isset(
$_POST[
"id"])) {
 
 1710            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1713        ilUtil::sendInfo($this->lng->txt(
"cont_selected_items_have_been_cut"), 
true);
 
 1719        $this->ctrl->redirect($this, 
"pages");
 
 1727        if (
$_GET[
"new_type"] == 
"pg") {
 
 1728            $this->ctrl->redirect($this, 
"pages");
 
 1730            $this->ctrl->redirect($this, 
"chapters");
 
 1742        if ($ot->getContentActivated()) {
 
 1749        $cont_exp->buildExportFile($opt);
 
 1760        $changelink = 
"<a href='" . $ilCtrl->getLinkTarget($this, 
"editMenuProperties") . 
"'>" . 
$lng->txt(
"change") . 
"</a>";
 
 1761        if (!$this->object->isActiveLMMenu()) {
 
 1762            $add = 
"<br />" . 
$lng->txt(
"cont_download_no_menu") . 
" " . $changelink;
 
 1763        } elseif (!$this->object->isActiveDownloads()) {
 
 1764            $add = 
"<br />" . 
$lng->txt(
"cont_download_no_download") . 
" " . $changelink;
 
 1767        $basetype = explode(
"_", $a_type);
 
 1768        $basetype = $basetype[0];
 
 1770        if ($this->object->getPublicExportFile($basetype) == $a_file) {
 
 1771            return $lng->txt(
"yes") . $add;
 
 1786        if (!isset($a_files)) {
 
 1789            foreach ($a_files as 
$f) {
 
 1790                $file = explode(
":", 
$f);
 
 1791                if (is_int(strpos($file[0], 
"_"))) {
 
 1792                    $file[0] = explode(
"_", $file[0])[0];
 
 1794                $export_dir = $this->
object->getExportDirectory($file[0]);
 
 1796                if ($this->object->getPublicExportFile($file[0]) ==
 
 1798                    $this->
object->setPublicExportFile($file[0], 
"");
 
 1800                    $this->
object->setPublicExportFile($file[0], $file[1]);
 
 1803            $this->
object->update();
 
 1805        $ilCtrl->redirectByClass(
"ilexportgui");
 
 1815        if (!isset(
$_POST[
"file"])) {
 
 1816            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 1819        if (count(
$_POST[
"file"]) > 1) {
 
 1820            $ilErr->raiseError($this->lng->txt(
"cont_select_max_one_item"), 
$ilErr->MESSAGE);
 
 1824        $export_dir = $this->
object->getOfflineDirectory();
 
 1826        $file = basename(
$_POST[
"file"][0]);
 
 1843        $cgui->setFormAction($this->ctrl->getFormAction($this));
 
 1844        $cgui->setHeaderText($this->lng->txt(
"cont_fix_tree_confirm"));
 
 1845        $cgui->setCancel($this->lng->txt(
"cancel"), 
"showMaintenance");
 
 1846        $cgui->setConfirm($this->lng->txt(
"cont_fix_tree"), 
"fixTree");
 
 1847        $issues = $this->
object->checkStructure();
 
 1849        if (count($issues) > 0) {
 
 1850            $mess = 
"Found Issues: <br>" . implode(
"<br>", $issues);
 
 1852        $this->tpl->setContent($cgui->getHTML() . $mess);
 
 1860        $this->
object->fixTree();
 
 1861        ilUtil::sendSuccess($this->lng->txt(
"cont_tree_fixed"), 
true);
 
 1862        $this->ctrl->redirect($this, 
"showMaintenance");
 
 1870        $a_export_format = 
"",
 
 1871        $a_active = 
"content",
 
 1872        $a_use_global_tabs = 
false,
 
 1873        $a_as_subtabs = 
false,
 
 1876        $a_export_all = 
false 
 1886        $ilHelp->setScreenIdComponent(
"lm");
 
 1888        if ($a_as_subtabs) {
 
 1889            $addcmd = 
"addSubTabTarget";
 
 1890            $getcmd = 
"getSubTabHTML";
 
 1892            $addcmd = 
"addTarget";
 
 1893            $getcmd = 
"getHTML";
 
 1896        $active[$a_active] = 
true;
 
 1898        if (!$this->object->isActiveLMMenu()) {
 
 1902        if ($a_use_global_tabs) {
 
 1915        $showViewInFrameset = 
true;
 
 1917        if ($showViewInFrameset && !$a_offline) {
 
 1920            $buttonTarget = 
"_top";
 
 1923        if ($a_export_format == 
"scorm") {
 
 1928        if (!$a_offline && $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"])) {
 
 1929            $ilCtrl->setParameterByClass(
"illmpresentationgui", 
"obj_id", 
$_GET[
"obj_id"]);
 
 1932                $ilCtrl->getLinkTargetByClass(
"illmpresentationgui", 
"layout"),
 
 1938            if ($active[
"content"]) {
 
 1939                $ilHelp->setScreenId(
"content");
 
 1940                $ilHelp->setSubScreenId(
"content");
 
 1942        } elseif ($a_offline) {
 
 1943            $tabs_gui->setForcePresentationOfSingleTab(
true);
 
 1946        if ($this->object->isActiveTOC() && $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"])) {
 
 1948                $ilCtrl->setParameterByClass(
"illmpresentationgui", 
"obj_id", 
$_GET[
"obj_id"]);
 
 1949                $link = $ilCtrl->getLinkTargetByClass(
"illmpresentationgui", 
"showTableOfContents");
 
 1951                if ($a_export_all) {
 
 1952                    $link = 
"./table_of_contents_" . $a_lang . 
".html";
 
 1954                    $link = 
"./table_of_contents.html";
 
 1968        if ($this->object->isActivePrintView() && $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"])) {
 
 1970                $ilCtrl->setParameterByClass(
"illmpresentationgui", 
"obj_id", 
$_GET[
"obj_id"]);
 
 1971                $link = $ilCtrl->getLinkTargetByClass(
"illmpresentationgui", 
"showPrintViewSelection");
 
 1985            $is_public = $this->
object->isActiveDownloadsPublic();
 
 1990        if ($this->object->isActiveDownloads() && !$a_offline && $is_public &&
 
 1991            $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"])) {
 
 1992            $ilCtrl->setParameterByClass(
"illmpresentationgui", 
"obj_id", 
$_GET[
"obj_id"]);
 
 1993            $link = $ilCtrl->getLinkTargetByClass(
"illmpresentationgui", 
"showDownloadList");
 
 2005        if ($a_export_format != 
"scorm" && !$a_offline) {
 
 2007                $ilCtrl->setParameterByClass(
"illmpresentationgui", 
"obj_id", 
$_GET[
"obj_id"]);
 
 2008                $link = $this->ctrl->getLinkTargetByClass(
 
 2009                    array(
"illmpresentationgui", 
"ilinfoscreengui"),
 
 2013                $link = 
"./info.html";
 
 2027            $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"]) && 
 
 2032                    "learning_progress",
 
 2033                    $this->ctrl->getLinkTargetByClass(array(
"illmpresentationgui", 
"illearningprogressgui"), 
"editManual"),
 
 2037                    $active[
"learning_progress"]
 
 2041                    "learning_progress",
 
 2042                    $this->ctrl->getLinkTargetByClass(array(
"illmpresentationgui", 
"illearningprogressgui"), 
"showtlt"),
 
 2046                    $active[
"learning_progress"]
 
 2053        $entries = $this->lmme_obj->getMenuEntries(
true);
 
 2054        if (count($entries) > 0 && $ilAccess->checkAccess(
"read", 
"", 
$_GET[
"ref_id"])) {
 
 2055            foreach ($entries as $entry) {
 
 2057                if ($entry[
"type"] == 
"intern") {
 
 2058                    $entry[
"link"] = ILIAS_HTTP_PATH . 
"/goto.php?target=" . $entry[
"link"];
 
 2062                if (!strstr($entry[
"link"], 
'://') && !strstr($entry[
"link"], 
'mailto:')) {
 
 2063                    $entry[
"link"] = 
"http://" . $entry[
"link"];
 
 2066                if (!strstr($entry[
"link"], 
'mailto:')) {
 
 2082        if (!$a_offline && $a_cur_page > 0) {
 
 2085                $page_id = $a_cur_page;
 
 2088                    ILIAS_HTTP_PATH . 
"/ilias.php?baseClass=ilLMEditorGUI&ref_id=" . 
$_GET[
"ref_id"] .
 
 2089                    "&obj_id=" . $page_id . 
"&to_page=1",
 
 2093                    $active[
"edit_page"]
 
 2099        $pl_names = $ilPluginAdmin->getActivePluginsForSlot(
IL_COMP_SERVICE, 
"UIComponent", 
"uihk");
 
 2100        $plugin_html = 
false;
 
 2101        foreach ($pl_names as $pl) {
 
 2103            $gui_class = $ui_plugin->getUIClassInstance();
 
 2104            $resp = $gui_class->modifyGUI(
 
 2105                "Modules/LearningModule",
 
 2120        $cont_exp->buildExportFile();
 
 2121        $this->offlineList();
 
 2131        if ($ot->getContentActivated()) {
 
 2136        $cont_exp->buildExportFile();
 
 2145        $cont_exp->buildExportFile();
 
 2157        if (!$a_omit_obj_id) {
 
 2160        $lmtree = $this->
object->getTree();
 
 2163            $path = $lmtree->getPathFull(
$obj_id);
 
 2165            $path = $lmtree->getPathFull($lmtree->getRootId());
 
 2167                $path[] = array(
"type" => 
"pg", 
"child" => $this->obj_id,
 
 2172        foreach ($path as $key => $row) {
 
 2173            if ($row[
"child"] == 1) {
 
 2174                $this->ctrl->setParameter($this, 
"obj_id", 
"");
 
 2175                $locator->addItem($this->object->getTitle(), $this->ctrl->getLinkTarget($this, 
"chapters"));
 
 2177                $title = $row[
"title"];
 
 2178                switch ($row[
"type"]) {
 
 2180                        $this->ctrl->setParameterByClass(
"ilstructureobjectgui", 
"obj_id", $row[
"child"]);
 
 2181                        $locator->addItem($title, $this->ctrl->getLinkTargetByClass(
"ilstructureobjectgui", 
"view"));
 
 2185                        $this->ctrl->setParameterByClass(
"illmpageobjectgui", 
"obj_id", $row[
"child"]);
 
 2186                        $locator->addItem($title, $this->ctrl->getLinkTargetByClass(
"illmpageobjectgui", 
"edit"));
 
 2191        if (!$a_omit_obj_id) {
 
 2192            $this->ctrl->setParameter($this, 
"obj_id", 
$_GET[
"obj_id"]);
 
 2212        $tpl->setContent($table->getHTML());
 
 2226        $tpl->setContent($table->getHTML());
 
 2237        if (is_array(
$_POST[
"userquest_id"])) {
 
 2238            foreach (
$_POST[
"userquest_id"] as $uqid) {
 
 2239                $uqid = explode(
":", $uqid);
 
 2242            ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 2244        $ilCtrl->redirect($this, 
"listBlockedUsers");
 
 2255        if (is_array(
$_POST[
"userquest_id"])) {
 
 2256            foreach (
$_POST[
"userquest_id"] as $uqid) {
 
 2257                $uqid = explode(
":", $uqid);
 
 2260            ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 2262        $ilCtrl->redirect($this, 
"listBlockedUsers");
 
 2272        if (!is_array(
$_POST[
"userquest_id"])) {
 
 2274            $ilCtrl->redirect($this, 
"listBlockedUsers");
 
 2278        foreach (
$_POST[
"userquest_id"] as $uqid) {
 
 2279            $uqid = explode(
":", $uqid);
 
 2281            if (!in_array(
$login, $rcps)) {
 
 2291                'rcp_to' => implode(
',', $rcps),
 
 2302        $link = chr(13) . chr(10) . chr(13) . chr(10);
 
 2303        $link .= $this->lng->txt(
'cont_blocked_users_mail_link');
 
 2304        $link .= chr(13) . chr(10) . chr(13) . chr(10);
 
 2306        return rawurlencode(base64_encode($link));
 
 2320        parent::setTitleAndDescription();
 
 2322        $ilHelp->setScreenIdComponent(
"lm");
 
 2342            $lng->txt(
"cont_chapters"),
 
 2343            $ilCtrl->getLinkTarget($this, 
"chapters")
 
 2349            $lng->txt(
"cont_all_pages"),
 
 2350            $ilCtrl->getLinkTarget($this, 
"pages")
 
 2356            $lng->txt(
"cont_short_titles"),
 
 2357            $ilCtrl->getLinkTargetByClass(
"illmeditshorttitlesgui", 
"")
 
 2361        if (
$lm_set->get(
"html_export_ids")) {
 
 2365                    $lng->txt(
"cont_html_export_ids"),
 
 2366                    $ilCtrl->getLinkTarget($this, 
"showExportIDsOverview")
 
 2371            $lng->loadLanguageModule(
"help");
 
 2374                $lng->txt(
"cont_online_help_ids"),
 
 2375                $ilCtrl->getLinkTarget($this, 
"showExportIDsOverview")
 
 2380                $lng->txt(
"help_tooltips"),
 
 2381                $ilCtrl->getLinkTarget($this, 
"showTooltipList")
 
 2388            $lng->txt(
"cont_internal_links"),
 
 2389            $ilCtrl->getLinkTarget($this, 
"listLinks")
 
 2395            $lng->txt(
"link_check"),
 
 2396            $ilCtrl->getLinkTarget($this, 
"linkChecker")
 
 2401            $lng->txt(
"history"),
 
 2402            $this->ctrl->getLinkTarget($this, 
"history")
 
 2408            $lng->txt(
"cont_maintenance"),
 
 2409            $ilCtrl->getLinkTarget($this, 
"showMaintenance")
 
 2415            $lng->txt(
"cont_subtitle_files"),
 
 2416            $ilCtrl->getLinkTargetByClass(
"ilmobmultisrtuploadgui", 
"")
 
 2422            $lng->txt(
"cont_import"),
 
 2423            $ilCtrl->getLinkTargetByClass(
"illmimportgui", 
"")
 
 2426        $ilTabs->activateSubTab($a_active);
 
 2427        $ilTabs->activateTab(
"content");
 
 2444            $lng->txt(
"cont_question_stats"),
 
 2445            $ilCtrl->getLinkTarget($this, 
"listQuestions")
 
 2451            $lng->txt(
"cont_blocked_users"),
 
 2452            $ilCtrl->getLinkTarget($this, 
"listBlockedUsers")
 
 2455        $ilTabs->activateSubTab($a_active);
 
 2470            $lng->txt(
"content"),
 
 2471            $this->ctrl->getLinkTarget($this, 
"chapters")
 
 2477            $lng->txt(
"info_short"),
 
 2478            $this->ctrl->getLinkTargetByClass(
"ilinfoscreengui", 
'showSummary')
 
 2484            $lng->txt(
"settings"),
 
 2485            $this->ctrl->getLinkTarget($this, 
'properties')
 
 2491            $lng->txt(
"objs_qst"),
 
 2492            $this->ctrl->getLinkTarget($this, 
"listQuestions")
 
 2498                'learning_progress',
 
 2499                $lng->txt(
"learning_progress"),
 
 2500                $this->ctrl->getLinkTargetByClass(array(
'illearningprogressgui'), 
'')
 
 2504        if ($this->object->getType() != 
"lm") {
 
 2508                $lng->txt(
"bib_data"),
 
 2509                $this->ctrl->getLinkTarget($this, 
"editBibItem")
 
 2515        $mdtab = $mdgui->getTab();
 
 2519                $lng->txt(
"meta_data"),
 
 2524        if ($this->object->getType() == 
"lm") {
 
 2528                $lng->txt(
"export"),
 
 2529                $this->ctrl->getLinkTargetByClass(
"ilexportgui", 
"")
 
 2534        if (
$rbacsystem->checkAccess(
'edit_permission', $this->object->getRefId())) {
 
 2537                $lng->txt(
"perm_settings"),
 
 2538                $this->ctrl->getLinkTargetByClass(array(get_class($this),
'ilpermissiongui'), 
"perm")
 
 2543            $ilTabs->activateTab($a_act);
 
 2547        $ilTabs->addNonTabbedLink(
 
 2549            $lng->txt(
"cont_presentation_view"),
 
 2550            "ilias.php?baseClass=ilLMPresentationGUI&ref_id=" . $this->object->getRefID(),
 
 2565            array(
"settings", 
"cont_style", 
"cont_lm_menu", 
"public_section",
 
 2566                "cont_glossaries", 
"cont_multilinguality", 
"obj_multilinguality",
 
 2570            $ilTabs->addSubTabTarget(
 
 2572                $this->ctrl->getLinkTarget($this, 
'properties'),
 
 2578            $ilTabs->addSubTabTarget(
 
 2580                $this->ctrl->getLinkTarget($this, 
'editStyleProperties'),
 
 2586            $ilTabs->addSubTabTarget(
 
 2588                $this->ctrl->getLinkTarget($this, 
'editMenuProperties'),
 
 2594            $ilTabs->addSubTabTarget(
 
 2596                $this->ctrl->getLinkTarget($this, 
'editGlossaries'),
 
 2603                $ilTabs->addSubTabTarget(
 
 2605                    $this->ctrl->getLinkTarget($this, 
'editPublicSection'),
 
 2611            $ilTabs->addSubTabTarget(
 
 2612                "obj_multilinguality",
 
 2613                $this->ctrl->getLinkTargetByClass(
"ilobjecttranslationgui", 
"")
 
 2617            if ($lti_settings->hasSettingsAccess()) {
 
 2618                $ilTabs->addSubTabTarget(
 
 2620                    $this->ctrl->getLinkTargetByClass(ilLTIProviderObjectSettingGUI::class)
 
 2624            $ilTabs->setSubTabActive($a_active);
 
 2635        if (!$ilAccess->checkAccessOfUser(
ANONYMOUS_USER_ID, 
"read", 
"", $this->object->getRefId())) {
 
 2641        $ilTabs->setTabActive(
"settings");
 
 2643        $this->tpl->addBlockFile(
 
 2646            "tpl.lm_public_selector.html",
 
 2647            "Modules/LearningModule" 
 2655        $modes = array(
"complete" => $this->lng->txt(
"all_pages"), 
"selected" => $this->lng->txt(
"selected_pages_only"));
 
 2657        $si->setOptions($modes);
 
 2658        $si->setValue($this->object->getPublicAccessMode());
 
 2659        $ilToolbar->addInputItem(
$si, 
true);
 
 2660        $ilToolbar->addFormButton($this->lng->txt(
"save"), 
"savePublicSectionAccess");
 
 2661        $ilToolbar->setFormAction($this->ctrl->getFormAction($this, 
"savePublicSectionAccess"));
 
 2663        if ($this->object->getPublicAccessMode() == 
"selected") {
 
 2664            $this->tpl->setCurrentBlock(
"select_pages");
 
 2665            $this->tpl->setVariable(
"FORMACTION", $this->ctrl->getLinkTarget($this, 
"savePublicSectionPages"));
 
 2668            $tree->setSelectMode(
"pages", 
true);
 
 2669            $tree->setSkipRootNode(
true);
 
 2671            $this->tpl->setVariable(
"EXPLORER", 
$tree->getHTML());
 
 2672            $this->tpl->setVariable(
"TXT_SAVE", $this->lng->txt(
"save"));
 
 2674            $this->tpl->parseCurrentBlock();
 
 2681        $this->
object->setPublicAccessMode(
$_POST[
"lm_public_mode"]);
 
 2682        $this->
object->updateProperties();
 
 2684        ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified"), 
true);
 
 2685        $this->ctrl->redirect($this, 
"editPublicSection");
 
 2693        $this->
object->setPublicAccessMode(
$_POST[
"lm_public_mode"]);
 
 2694        $this->
object->updateProperties();
 
 2695        ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified"), 
true);
 
 2696        $this->ctrl->redirect($this, 
"editPublicSection");
 
 2705        ilUtil::sendSuccess($this->lng->txt(
"msg_obj_modified"), 
true);
 
 2706        $this->ctrl->redirect($this, 
"editPublicSection");
 
 2722            $this->object->getId(),
 
 2723            $this->object->getType()
 
 2725        $hist_gui->initTable();
 
 2726        $hist_gui->setCommentVisibility($this->object->isActiveHistoryUserComments());
 
 2728        $this->tpl->setContent($hist_gui->getHTML());
 
 2744        $actions->setSelectionHeaderClass(
'small');
 
 2745        $actions->setItemLinkClass(
'xsmall');
 
 2746        $actions->setListTitle($this->lng->txt(
'actions'));
 
 2748        $this->ctrl->setParameterByClass(
'ilLMPageObjectGUI', 
'obj_id', $row[
'page_id']);
 
 2750            $this->lng->txt(
'edit'),
 
 2752            $this->ctrl->getLinkTargetByClass(
'ilLMPageObjectGUI', 
'edit')
 
 2754        $this->ctrl->clearParametersByClass(
'ilLMPageObjectGUI');
 
 2755        $row[
'action_html'] = 
$actions->getHTML();
 
 2774            $chb = 
new ilCheckboxInputGUI($this->lng->txt(
'link_check_message_a'), 
'link_check_message');
 
 2777            $chb->setOptionTitle($this->lng->txt(
'link_check_message_b'));
 
 2780            $toolbar->addFormButton($this->lng->txt(
'save'), 
'saveLinkCheck');
 
 2781            $toolbar->setFormAction($this->ctrl->getLinkTarget($this, 
'saveLinkCheck'));
 
 2785        $tgui->setLinkChecker($this->link_checker_obj)
 
 2786             ->setRowHandler($this)
 
 2787             ->setRefreshButton($this->lng->txt(
'refresh'), 
'refreshLinkCheck');
 
 2789        return $tpl->setContent($tgui->prepareHTML()->getHTML() . 
$toolbar->getHTML());
 
 2798        $link_check_notify->setUserId(
$ilUser->getId());
 
 2799        $link_check_notify->setObjId($this->object->getId());
 
 2801        if (
$_POST[
'link_check_message']) {
 
 2802            ilUtil::sendSuccess($this->lng->txt(
'link_check_message_enabled'));
 
 2803            $link_check_notify->addNotifier();
 
 2805            ilUtil::sendSuccess($this->lng->txt(
'link_check_message_disabled'));
 
 2806            $link_check_notify->deleteNotifier();
 
 2818        $this->link_checker_obj->checkLinks();
 
 2819        ilUtil::sendSuccess($this->lng->txt(
'link_checker_refreshed'));
 
 2831        $this->link_checker_obj->setObjId($this->object->getId());
 
 2839        $this->lmme_obj->setObjId($this->object->getId());
 
 2856        $ilTabs->setTabActive(
"settings");
 
 2859        $ilToolbar->addButton(
 
 2860            $this->lng->txt(
"lm_menu_select_internal_object"),
 
 2861            $ilCtrl->getLinkTarget($this, 
"showEntrySelector")
 
 2865        $this->tpl->setContent($form->getHTML());
 
 2881        $ti = 
new ilTextInputGUI($this->lng->txt(
"lm_menu_entry_title"), 
"title");
 
 2882        $ti->setMaxLength(255);
 
 2884        $form->addItem($ti);
 
 2887        $ta = 
new ilTextInputGUI($this->lng->txt(
"lm_menu_entry_target"), 
"target");
 
 2888        $ta->setMaxLength(255);
 
 2890        $form->addItem($ta);
 
 2892        if ($a_mode == 
"edit") {
 
 2894            $this->lmme_obj->readEntry($_REQUEST[
"menu_entry"]);
 
 2895            $ti->setValue($this->lmme_obj->getTitle());
 
 2896            $ta->setValue($this->lmme_obj->getTarget());
 
 2899        if (isset(
$_GET[
"link_ref_id"])) {
 
 2900            $link_ref_id = (int) 
$_GET[
"link_ref_id"];
 
 2905            $target_link = $obj_type . 
"_" . $link_ref_id;
 
 2906            $ti->setValue($title);
 
 2907            $ta->setValue($target_link);
 
 2911            $hi->setValue($link_ref_id);
 
 2912            $form->addItem($hi);
 
 2917        if ($a_mode == 
"create") {
 
 2918            $form->addCommandButton(
"saveMenuEntry", 
$lng->txt(
"save"));
 
 2919            $form->addCommandButton(
"editMenuProperties", 
$lng->txt(
"cancel"));
 
 2920            $form->setTitle(
$lng->txt(
"lm_menu_new_entry"));
 
 2922            $form->addCommandButton(
"updateMenuEntry", 
$lng->txt(
"save"));
 
 2923            $form->addCommandButton(
"editMenuProperties", 
$lng->txt(
"cancel"));
 
 2924            $form->setTitle(
$lng->txt(
"lm_menu_edit_entry"));
 
 2927        $form->setFormAction($ilCtrl->getFormAction($this));
 
 2940        if (empty(
$_POST[
"title"])) {
 
 2942            $ilCtrl->redirect($this, 
"addMenuEntry");
 
 2944        if (empty(
$_POST[
"target"])) {
 
 2946            $ilCtrl->redirect($this, 
"addMenuEntry");
 
 2950        $this->lmme_obj->setTitle(
$_POST[
"title"]);
 
 2951        $this->lmme_obj->setTarget(
$_POST[
"target"]);
 
 2952        $this->lmme_obj->setLinkRefId(
$_POST[
"link_ref_id"]);
 
 2954        if (
$_POST[
"link_ref_id"]) {
 
 2955            $this->lmme_obj->setLinkType(
"intern");
 
 2958        $this->lmme_obj->create();
 
 2960        ilUtil::sendSuccess($this->lng->txt(
"msg_entry_added"), 
true);
 
 2961        $this->ctrl->redirect($this, 
"editMenuProperties");
 
 2971        if (empty(
$_GET[
"menu_entry"])) {
 
 2972            $ilErr->raiseError($this->lng->txt(
"no_menu_entry_id"), 
$ilErr->MESSAGE);
 
 2976        $this->lmme_obj->delete(
$_GET[
"menu_entry"]);
 
 2978        ilUtil::sendSuccess($this->lng->txt(
"msg_entry_removed"), 
true);
 
 2979        $this->ctrl->redirect($this, 
"editMenuProperties");
 
 2994        $ilTabs->setTabActive(
"settings");
 
 2998        if (empty(
$_GET[
"menu_entry"])) {
 
 2999            $ilErr->raiseError($this->lng->txt(
"no_menu_entry_id"), 
$ilErr->MESSAGE);
 
 3002        $ilCtrl->saveParameter($this, array(
"menu_entry"));
 
 3003        $ilToolbar->addButton(
 
 3004            $this->lng->txt(
"lm_menu_select_internal_object"),
 
 3005            $ilCtrl->getLinkTarget($this, 
"showEntrySelector")
 
 3009        $this->tpl->setContent($form->getHTML());
 
 3019        if (empty($_REQUEST[
"menu_entry"])) {
 
 3020            $ilErr->raiseError($this->lng->txt(
"no_menu_entry_id"), 
$ilErr->MESSAGE);
 
 3024        if (empty(
$_POST[
"title"])) {
 
 3025            $ilErr->raiseError($this->lng->txt(
"please_enter_title"), 
$ilErr->MESSAGE);
 
 3027        if (empty(
$_POST[
"target"])) {
 
 3028            $ilErr->raiseError($this->lng->txt(
"please_enter_target"), 
$ilErr->MESSAGE);
 
 3032        $this->lmme_obj->readEntry($_REQUEST[
"menu_entry"]);
 
 3033        $this->lmme_obj->setTitle(
$_POST[
"title"]);
 
 3034        $this->lmme_obj->setTarget(
$_POST[
"target"]);
 
 3035        if (
$_POST[
"link_ref_id"]) {
 
 3036            $this->lmme_obj->setLinkType(
"intern");
 
 3038        if (is_int(strpos(
$_POST[
"target"], 
"."))) {
 
 3039            $this->lmme_obj->setLinkType(
"extern");
 
 3041        $this->lmme_obj->update();
 
 3043        ilUtil::sendSuccess($this->lng->txt(
"msg_entry_updated"), 
true);
 
 3044        $this->ctrl->redirect($this, 
"editMenuProperties");
 
 3054        $ilTabs->setTabActive(
"settings");
 
 3057        $ilCtrl->saveParameter($this, array(
"menu_entry"));
 
 3059        $this->tpl->addBlockFile(
"ADM_CONTENT", 
"adm_content", 
"tpl.lm_menu_object_selector.html", 
"Modules/LearningModule");
 
 3065        $exp->setExpand(
$_GET[
"lm_menu_expand"] ? 
$_GET[
"lm_menu_expand"] : $this->tree->readRootId());
 
 3066        $exp->setExpandTarget($this->ctrl->getLinkTarget($this, 
'showEntrySelector'));
 
 3067        $exp->setTargetGet(
"ref_id");
 
 3068        $exp->setRefId($this->cur_ref_id);
 
 3070        $sel_types = array(
'mcst', 
'mep', 
'cat', 
'lm',
'glo',
'frm',
'exc',
'tst',
'svy', 
'chat', 
'wiki', 
'sahs',
 
 3071            "crs", 
"grp", 
"book", 
"tst", 
"file");
 
 3072        $exp->setSelectableTypes($sel_types);
 
 3076        $output = $exp->getOutput();
 
 3079        foreach ($exp->format_options as $node) {
 
 3080            if (!$node[
"container"]) {
 
 3081                $pages[] = $node[
"child"];
 
 3086        $this->tpl->setVariable(
"TXT_SET_PUBLIC_MODE", $this->lng->txt(
"set_public_mode"));
 
 3087        $this->tpl->setVariable(
"TXT_CHOOSE_PUBLIC_MODE", $this->lng->txt(
"choose_public_mode"));
 
 3088        $modes = array(
"complete" => $this->lng->txt(
"all_pages"), 
"selected" => $this->lng->txt(
"selected_pages_only"));
 
 3089        $select_public_mode = 
ilUtil::formSelect($this->object->getPublicAccessMode(), 
"lm_public_mode", $modes, 
false, 
true);
 
 3090        $this->tpl->setVariable(
"SELECT_PUBLIC_MODE", $select_public_mode);
 
 3092        $this->tpl->setVariable(
"TXT_EXPLORER_HEADER", $this->lng->txt(
"choose_public_pages"));
 
 3093        $this->tpl->setVariable(
"EXP_REFRESH", $this->lng->txt(
"refresh"));
 
 3094        $this->tpl->setVariable(
"EXPLORER", $output);
 
 3095        $this->tpl->setVariable(
"ONCLICK", $js_pages);
 
 3096        $this->tpl->setVariable(
"TXT_CHECKALL", $this->lng->txt(
"check_all"));
 
 3097        $this->tpl->setVariable(
"TXT_UNCHECKALL", $this->lng->txt(
"uncheck_all"));
 
 3098        $this->tpl->setVariable(
"TXT_SAVE", $this->lng->txt(
"save"));
 
 3099        $this->tpl->setVariable(
"FORMACTION", $this->ctrl->getLinkTarget($this, 
"savePublicSection"));
 
 3109        if (!isset(
$_POST[
"id"])) {
 
 3110            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 3112        if (count(
$_POST[
"id"]) > 1) {
 
 3113            $ilErr->raiseError($this->lng->txt(
"cont_select_max_one_item"), 
$ilErr->MESSAGE);
 
 3115        if (
$_POST[
"id"][0] != $this->object->getHeaderPage()) {
 
 3116            $this->
object->setHeaderPage(
$_POST[
"id"][0]);
 
 3118            $this->
object->setHeaderPage(0);
 
 3120        $this->
object->updateProperties();
 
 3121        $this->ctrl->redirect($this, 
"pages");
 
 3131        if (!isset(
$_POST[
"id"])) {
 
 3132            $ilErr->raiseError($this->lng->txt(
"no_checkbox"), 
$ilErr->MESSAGE);
 
 3134        if (count(
$_POST[
"id"]) > 1) {
 
 3135            $ilErr->raiseError($this->lng->txt(
"cont_select_max_one_item"), 
$ilErr->MESSAGE);
 
 3137        if (
$_POST[
"id"][0] != $this->object->getFooterPage()) {
 
 3138            $this->
object->setFooterPage(
$_POST[
"id"][0]);
 
 3140            $this->
object->setFooterPage(0);
 
 3142        $this->
object->updateProperties();
 
 3143        $this->ctrl->redirect($this, 
"pages");
 
 3155        ilUtil::sendSuccess($this->lng->txt(
"lm_save_titles"), 
true);
 
 3156        $ilCtrl->redirect($this, 
"chapters");
 
 3171            $parent_id = $this->lm_tree->getParentId($node_id);
 
 3174            $parent_id = $node_id;
 
 3178        for (
$i = 1; 
$i <= $num; 
$i++) {
 
 3180            $chap->setType(
"st");
 
 3181            $chap->setTitle(
$lng->txt(
"cont_new_chap"));
 
 3182            $chap->setLMId($this->object->getId());
 
 3187        $ilCtrl->redirect($this, 
"chapters");
 
 3202        $ilLog->write(
"InsertChapterClip, num: $num, node_id: $node_id, " .
 
 3205        if (!$first_child) {    
 
 3206            $parent_id = $this->lm_tree->getParentId($node_id);
 
 3209            $parent_id = $node_id;
 
 3214        $chapters = 
$ilUser->getClipboardObjects(
"st", 
true);
 
 3215        $copied_nodes = array();
 
 3216        foreach ($chapters as $chap) {
 
 3217            $ilLog->write(
"Call pasteTree, Target LM: " . $this->object->getId() . 
", Chapter ID: " . $chap[
"id"]
 
 3218                . 
", Parent ID: " . $parent_id . 
", Target: " . $target);
 
 3224                $chap[
"insert_time"],
 
 3233            $ilUser->clipboardDeleteObjectsOfType(
"pg");
 
 3234            $ilUser->clipboardDeleteObjectsOfType(
"st");
 
 3238        $this->
object->checkTree();
 
 3239        $ilCtrl->redirect($this, 
"chapters");
 
 3251        $ilAccess = 
$DIC->access();
 
 3255        if ($ilAccess->checkAccess(
"read", 
"", $a_target)) {
 
 3256            $_GET[
"baseClass"] = 
"ilLMPresentationGUI";
 
 3257            $_GET[
"ref_id"] = $a_target;
 
 3258            $_GET[
"cmd"] = 
"resume";
 
 3259            include(
"ilias.php");
 
 3261        } elseif ($ilAccess->checkAccess(
"visible", 
"", $a_target)) {
 
 3262            $_GET[
"baseClass"] = 
"ilLMPresentationGUI";
 
 3263            $_GET[
"ref_id"] = $a_target;
 
 3264            $_GET[
"cmd"] = 
"infoScreen";
 
 3265            include(
"ilias.php");
 
 3269                $lng->txt(
"msg_no_perm_read_item"),
 
 3288        if (!is_array($items)) {
 
 3290            $ilCtrl->redirect($this, $a_return);
 
 3294        foreach ($items as $k => $item) {
 
 3299        foreach ($todel as $k) {
 
 3306        $ilCtrl->redirect($this, $a_return);
 
 3318        if (!is_array($items)) {
 
 3320            $ilCtrl->redirect($this, 
"chapters");
 
 3324        foreach ($items as $k => $item) {
 
 3329        foreach ($todel as $k) {
 
 3335        $ilCtrl->redirect($this, 
"chapters");
 
 3368            $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
 
 3369            $lm_tree = $this->
object->getTree();
 
 3370            $childs = $lm_tree->getChilds($lm_tree->readRootId());
 
 3371            $options = array(
"" => 
$lng->txt(
"all"));
 
 3372            foreach ($childs as 
$c) {
 
 3373                $options[
$c[
"child"]] = 
$c[
"title"];
 
 3376            $si->setOptions($options);
 
 3378            $ilToolbar->addInputItem(
$si, 
true);
 
 3379            $ilToolbar->addFormButton(
$lng->txt(
"help_filter"), 
"filterHelpChapters");
 
 3386        $tpl->setContent($tbl->getHTML());
 
 3400        $ilCtrl->redirect($this, 
"showExportIDsOverview");
 
 3414        if (is_array(
$_POST[
"exportid"])) {
 
 3415            foreach (
$_POST[
"exportid"] as $pg_id => $exp_id) {
 
 3416                if ($exp_id != 
"" && !preg_match(
 
 3417                    "/^([a-zA-Z]+)[0-9a-zA-Z_]*$/",
 
 3426                $lng->txt(
"cont_exp_ids_not_resp_format3") . 
" " .
 
 3427                $lng->txt(
"cont_exp_ids_not_resp_format2"));
 
 3433        if (is_array(
$_POST[
"exportid"])) {
 
 3434            foreach (
$_POST[
"exportid"] as $pg_id => $exp_id) {
 
 3436                    $this->object->getId(),
 
 3444        ilUtil::sendSuccess(
$lng->txt(
"cont_saved_export_ids"), 
true);
 
 3445        $ilCtrl->redirect($this, 
"showExportIdsOverview");
 
 3459        if (is_array(
$_POST[
"screen_ids"])) {
 
 3460            foreach (
$_POST[
"screen_ids"] as $chap => $ids) {
 
 3461                $ids = explode(
"\n", $ids);
 
 3465        ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3466        $ilCtrl->redirect($this, 
"showExportIdsOverview");
 
 3489        $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
 
 3490        $ti = 
new ilTextInputGUI($this->lng->txt(
"help_tooltip_id"), 
"tooltip_id");
 
 3491        $ti->setMaxLength(200);
 
 3493        $ilToolbar->addInputItem($ti, 
true);
 
 3494        $ilToolbar->addFormButton(
$lng->txt(
"add"), 
"addTooltip");
 
 3495        $ilToolbar->addSeparator();
 
 3502        $si->setOptions($options);
 
 3504        $ilToolbar->addInputItem(
$si, 
true);
 
 3505        $ilToolbar->addFormButton(
$lng->txt(
"help_filter"), 
"filterTooltips");
 
 3509        $tpl->setContent($tbl->getHTML());
 
 3524        if (trim($tt_id) != 
"") {
 
 3525            if (is_int(strpos($tt_id, 
"_"))) {
 
 3527                ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3529                $fu = strpos($tt_id, 
"_");
 
 3530                $comp = substr($tt_id, 0, $fu);
 
 3536        $ilCtrl->redirect($this, 
"showTooltipList");
 
 3551        $ilCtrl->redirect($this, 
"showTooltipList");
 
 3566        if (is_array(
$_POST[
"text"])) {
 
 3567            foreach (
$_POST[
"text"] as $id => $text) {
 
 3574            ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3576        $ilCtrl->redirect($this, 
"showTooltipList");
 
 3587        if (is_array(
$_POST[
"id"])) {
 
 3588            foreach (
$_POST[
"id"] as $id) {
 
 3591            ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3593        $ilCtrl->redirect($this, 
"showTooltipList");
 
 3613        if ($a_def_option != 
"") {
 
 3617            $layout->addOption(
new ilRadioOption(
"<table><tr><td>" . $im_tag . 
"</td><td><b>" .
 
 3618                $lng->txt(
"cont_lm_default_layout") .
 
 3619                "</b>: " . 
$lng->txt(
"cont_layout_" . $a_def_option) .
 
 3620                "</td></tr></table>", 
""));
 
 3627            $layout->addOption(
new ilRadioOption(
"<table><tr><td style='padding: 0px 5px 5px;'>" .
 
 3628                $im_tag . 
"</td><td style='padding:5px;'><b>" . 
$lng->txt(
"cont_layout_" . $l) . 
"</b>: " .
 
 3629                $lng->txt(
"cont_layout_" . $l . 
"_desc") . 
"</td></tr></table>", $l));
 
 3641        $ilCtrl->setParameter($this, 
"hierarchy", 
"1");
 
 3655        if (!is_array(
$_POST[
"id"])) {
 
 3658            if ($a_in_hierarchy) {
 
 3659                $ilCtrl->redirect($this, 
"chapters");
 
 3661                $ilCtrl->redirect($this, 
"pages");
 
 3667        $tpl->setContent($this->form->getHTML());
 
 3680        if (is_array(
$_POST[
"id"])) {
 
 3681            foreach (
$_POST[
"id"] as $id) {
 
 3684                $this->form->addItem($hi);
 
 3688            $lng->txt(
"cont_layout"),
 
 3690            $this->object->getLayout()
 
 3692        $this->form->addItem($layout);
 
 3694        $this->form->addCommandButton(
"savePageLayout", 
$lng->txt(
"save"));
 
 3695        $this->form->addCommandButton(
"pages", 
$lng->txt(
"cancel"));
 
 3697        $this->form->setTitle(
$lng->txt(
"cont_set_layout"));
 
 3698        $this->form->setFormAction($ilCtrl->getFormAction($this));
 
 3709        $ilCtrl->setParameter($this, 
"hierarchy", 
$_GET[
"hierarchy"]);
 
 3711        foreach (
$_POST[
"id"] as $id) {
 
 3718        ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3720        if (
$_GET[
"hierarchy"] == 1) {
 
 3721            $ilCtrl->redirect($this, 
"chapters");
 
 3723            $ilCtrl->redirect($this, 
"pages");
 
 3746        $ilTabs->setTabActive(
"settings");
 
 3749        $ilToolbar->addButton(
 
 3751            $ilCtrl->getLinkTarget($this, 
"showLMGlossarySelector")
 
 3756        $tpl->setContent($tab->getHTML());
 
 3775        $ilTabs->setTabActive(
"settings");
 
 3779        $exp->setExpand(
$_GET[
"search_root_expand"] ? 
$_GET[
"search_root_expand"] : 
$tree->readRootId());
 
 3780        $exp->setExpandTarget($ilCtrl->getLinkTarget($this, 
'showLMGlossarySelector'));
 
 3781        $exp->setTargetClass(get_class($this));
 
 3782        $exp->setCmd(
'confirmGlossarySelection');
 
 3783        $exp->setClickableTypes(array(
"glo"));
 
 3784        $exp->addFilter(
"glo");
 
 3788        $tpl->setContent($exp->getOutput());
 
 3801        $ilCtrl->setParameter($this, 
"glo_ref_id", 
$_GET[
"root_id"]);
 
 3802        $cgui->setFormAction($ilCtrl->getFormAction($this));
 
 3803        $cgui->setHeaderText(
$lng->txt(
"cont_link_glo_in_lm"));
 
 3804        $cgui->setCancel(
$lng->txt(
"no"), 
"selectLMGlossary");
 
 3805        $cgui->setConfirm(
$lng->txt(
"yes"), 
"selectLMGlossaryLink");
 
 3806        $tpl->setContent($cgui->getHTML());
 
 3817        $glo_ref_id = (int) 
$_GET[
"glo_ref_id"];
 
 3819        $this->
object->autoLinkGlossaryTerms($glo_ref_id);
 
 3835        $glos = $this->
object->getAutoGlossaries();
 
 3836        $glo_ref_id = (int) 
$_GET[
"glo_ref_id"];
 
 3838        if (!in_array($glo_id, $glos)) {
 
 3841        $this->
object->setAutoGlossaries($glos);
 
 3842        $this->
object->update();
 
 3844        ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3845        $ilCtrl->redirect($this, 
"editGlossaries");
 
 3859        $this->
object->removeAutoGlossary((
int) 
$_GET[
"glo_id"]);
 
 3860        $this->
object->update();
 
 3862        ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"), 
true);
 
 3863        $ilCtrl->redirect($this, 
"editGlossaries");
 
 3876        $ilCtrl->setParameter($this, 
"transl", 
"");
 
 3877        if (
$_GET[
"lang_switch_mode"] == 
"short_titles") {
 
 3878            $ilCtrl->redirectByClass(
"illmeditshorttitlesgui", 
"");
 
 3880        $ilCtrl->redirect($this, 
"chapters");
 
 3893        $ilCtrl->setParameter($this, 
"transl", 
$_GET[
"totransl"]);
 
 3894        if (
$_GET[
"lang_switch_mode"] == 
"short_titles") {
 
 3895            $ilCtrl->redirectByClass(
"illmeditshorttitlesgui", 
"");
 
 3897        $ilCtrl->redirect($this, 
"chapters");
 
 3903        return parent::redrawHeaderActionObject();
 
if(!defined('PATH_SEPARATOR')) $GLOBALS['_PEAR_default_error_mode']
An exception for terminatinating execution or to throw for unit testing.
error($a_errmsg)
set error message @access public
User interface class for advanced drop-down selection lists.
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
Confirmation screen class.
Export class for content objects.
static isJobActive($a_job_id)
Check if given job is currently active.
Class ilECSLearningModuleSettings.
static getContentObjectId()
static getContentObjectType()
static setAction($a_action)
static storeContentObject($a_type, $a_id, $a_action="cut")
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Export User Interface Class.
static saveScreenIdsForChapter($a_chap, $a_ids)
Save screen ids for chapter.
static addTooltip($a_tt_id, $a_text, $a_module_id=0)
Add tooltip.
static updateTooltip($a_id, $a_text, $a_tt_id)
Update tooltip.
static getTooltipComponents($a_module_id=0)
Get all tooltip components.
static deleteTooltip($a_id)
Delete tooltip.
Copyright (c) 1998-2014 ILIAS open source, Extended GPL, see docs/LICENSE Date: 24....
static _createEntry( $a_obj_id, $a_action, $a_info_params="", $a_obj_type="", $a_user_comment="", $a_update_last=false)
Creates a new history entry for an object.
Base exception class for learning modules.
TableGUI class for glossary tables.
Import related features for learning modules.
Handler class for multi srt upload in learning modules.
static getInstance(&$a_content_obj, $a_id=0, $a_halt=true)
static _lookupType($a_obj_id, $a_lm_id=0)
Lookup type.
static clipboardCopy($a_cont_obj_id, $a_ids)
Copy a set of chapters/pages into the clipboard.
static _lookupContObjID($a_id)
get learning module / digibook id for lm object
static clipboardCut($a_cont_obj_id, $a_ids)
Copy a set of chapters/pages into the clipboard.
static saveTitles($a_lm, $a_titles, $a_lang="-")
Save titles for lm objects.
static saveExportId($a_lm_id, $a_lmobj_id, $a_exp_id, $a_type="pg")
Save export id.
static updateInternalLinks($a_copied_nodes, $a_parent_type="lm")
Update internal links, after multiple pages have been copied.
static _lookupTitle($a_obj_id)
Lookup title.
static _writePublicAccessStatus($a_pages, $a_cont_obj_id)
update public access flags in lm_data for all pages of a content object@access public
static putInTree($a_obj, $a_parent_id="", $a_target_node_id="")
put this object into content object tree
static writeLayout($a_obj_id, $a_layout, $a_lm=null)
Write layout setting.
static pasteTree( $a_target_lm, $a_item_id, $a_parent_id, $a_target, $a_insert_time, &$a_copied_nodes, $a_as_copy=false, $a_source_lm=null)
Paste item (tree) from clipboard to current lm.
static _getPresentationTitle( $a_pg_id, $a_mode=self::CHAPTER_TITLE, $a_include_numbers=false, $a_time_scheduled_activation=false, $a_force_content=false, $a_lm_id=0, $a_lang="-", $a_include_short=false)
presentation title doesn't have to be page title, it may be chapter title + page title or chapter tit...
TableGUI class for all pages of a learning module.
const LP_MODE_COLLECTION_TLT
const LP_MODE_COLLECTION_MANUAL
GUI class for LTI provider object settings.
static checkAccess($a_ref_id, $a_allow_only_read=true)
check access to learning progress
const LP_CONTEXT_REPOSITORY
Class ilObjUserTrackingGUI.
class for checking external links in page objects.
static _getNotifyStatus($a_usr_id, $a_obj_id)
class ilLinkCheckerTableGUI
class for checking external links in page objects Normally used in Cron jobs, but should be extensibl...
static _getLink($a_ref_id, $a_type='', $a_params=array(), $append="")
TableGUI class for (broken) links in learning module.
manifest.xml file not found-exception for import
Upload SRT files to a set of media objects.
This class represents a non editable value in a property form.
static setNotification($type, $user_id, $id, $status=true)
Set notification status for object and user.
static hasNotification($type, $user_id, $id)
Check notification status for object and user.
const TYPE_LM_BLOCKED_USERS
Class ilObjContentObjectGUI.
fixTreeConfirm()
confirm screen for tree fixing
addMenuEntry()
display add menu entry form
setPageLayout($a_in_hierarchy=false)
Set layout for multipl pages.
deleteTooltips()
Delete tooltips.
removeLMGlossary()
Remove lm glossary.
deleteMenuEntry()
drop a menu entry
sendMailToBlockedUsers()
Send Mail to blocked users.
properties()
edit properties form
selectLMGlossary()
Select lm glossary.
saveExportIds()
Save export IDs.
filterTooltips()
Filter tooltips.
showExportIDsOverview($a_validation=false)
Show export IDs overview.
savePageLayout()
Save page layout.
deleteStyle()
Delete Style.
static getMultiLangHeader($a_lm_id, $a_gui_class, $a_mode="")
Get multi lang header.
setTabs($a_act="")
output tabs
filterHelpChapters()
Filter help chapters.
unlockQuestion()
Unlock blocked question.
getContextPath($a_endnode_id, $a_startnode_id=1)
get context path in content object tree
addLocations($a_omit_obj_id=false)
display locator
confirmGlossarySelection()
Confirm glossary selection.
importObject()
display dialogue for importing XML-LeaningObjects
cutItems($a_return="chapters")
Copy items to clipboard, then cut them from the current tree.
showMaintenance()
Show maintenance.
showActions($a_actions)
show possible action (form buttons)
selectHeader()
select page as header
savePublicSectionPages()
Saves public lm pages.
importFileObject($parent_id=null, $a_catch_errors=true)
display status information or report errors messages in case of error
initSetPageLayoutForm()
Init set page layout form.
savePublicSectionAccess()
Saves lm access mode.
insertChapter()
Insert (multiple) chapters at node.
executeCommand()
execute command
setilLMMenu( $a_offline=false, $a_export_format="", $a_active="content", $a_use_global_tabs=false, $a_as_subtabs=false, $a_cur_page=0, $a_lang="", $a_export_all=false)
get lm menu html
saveAllTitles()
Save all titles of chapters/pages.
formatInvalidLinkArray(array $row)
editStyleProperties()
Edit style properties.
copyItems()
Copy items to clipboard.
saveMenuProperties()
save properties
initPropertiesForm()
Init properties form.
proceedDragDrop()
proceed drag and drop operations on pages/chapters
publishExportFile($a_files)
download export file
__construct($a_data, $a_id=0, $a_call_by_reference=true, $a_prepare_output=false)
Constructor.
confirmedDelete($a_parent_subobj_id=0)
delete page object or structure objects
exportSCORM()
create scorm package
pasteChapter($a_parent_subobj_id=0)
paste chapter
exportHTML()
create html package
saveHelpMapping()
Save help mapping.
cutChapter()
Cut chapter(s)
saveTooltips()
Save tooltips.
exportObject()
export object
getPropertiesFormValues()
Get values for properties form.
editMasterLanguage()
Edit master language.
static _goto($a_target)
redirect script
popup()
popup window for wysiwyg editor
saveMenuEntry()
save new menu entry
getPublicAccessColValue($a_type, $a_file)
Get public access value for export table.
showTooltipList()
Show export IDs overview.
initMenuForm()
Init menu form.
listLinks()
List all broken links.
listQuestions()
List questions.
selectFooter()
select page as footer
createStyle()
Create Style.
setContentSubTabs($a_active)
Set pages tabs.
initMenuEntryForm($a_mode="edit")
Init menu entry form.
initStylePropertiesForm()
Init style properties form.
setSubTabs($a_active)
Set sub tabs.
setPageLayoutInHierarchy()
Set layout for multipl pages.
saveProperties()
save properties
switchToLanguage()
Switch to language.
createPDF()
export content object
listBlockedUsers()
List blocked users.
updateMenuEntry()
update a menu entry
insertChapterClip()
Insert Chapter from clipboard.
activatePages()
activates or deactivates pages
moveChapter($a_parent_subobj_id=0)
move a single chapter (selection)
downloadPDFFile()
download export file
afterSave(ilObject $a_new_object)
Post (successful) object creation hook.
view()
view content object
explorer()
output explorer tree
static getLayoutOption($a_txt, $a_var, $a_def_option="")
Get layout option.
selectLMGlossaryLink()
Select a glossary and link all its terms.
cancelDelete()
cancel delete
showLMGlossarySelector()
Select LM Glossary.
copyChapter($a_parent_subobj_id=0)
copy a single chapter (selection)
initImportForm($a_new_type)
Init import form.
editMenuEntry()
edit menu entry form
getBlockedUsersMailSignature()
Get mail signature for blocked users.
editGlossaries()
Edit automatically linked glossaries.
saveStyleSettings()
Save style settings.
setQuestionsSubTabs($a_active)
Set pages tabs.
export()
export content object
addTabs($a_act="")
Adds tabs.
resetNumberOfTries()
Reset number of tries.
editMenuProperties()
Edit menu properies.
Class ilObjContentObject.
static getAvailableLayouts()
get all available lm layouts
static isOnlineHelpModule($a_id, $a_as_obj_id=false)
Is module an online module.
Class ilObjLearningModule.
Class ilObjStyleSheetGUI.
static _lookupStandard($a_id)
Lookup standard flag.
static _getStandardStyles( $a_exclude_default_style=false, $a_include_deactivated=false, $a_scope=0)
Get standard styles.
static _lookupLogin($a_user_id)
lookup login
GUI class for the workflow of copying objects.
static getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
Class ilObjectGUI Basic methods of all Output classes.
prepareOutput($a_show_subobjects=true)
prepare output
viewObject()
viewObject container presentation for "administration -> repository, trash, permissions"
static _gotoRepositoryRoot($a_raise_error=false)
Goto repository root.
getCreationMode()
get creation mode
addHeaderAction()
Add header action menu.
createObject()
create new object form
setTabs()
set admin tabs @access public
setTitleAndDescription()
called by prepare output
static getInstance($a_obj_id)
GUI class for object translation handling.
static getInstance($a_obj_id)
Get instance.
Class ilObject Basic functions for all objects.
static _lookupObjId($a_id)
update()
update object in db
static _lookupTitle($a_id)
lookup object title
static _lookupObjectId($a_ref_id)
lookup object id
getRefId()
get reference id @access public
static _lookupType($a_id, $a_reference=false)
lookup object type
Page multilinguality GUI class.
static _writeActive( $a_id, $a_parent_type, $a_active, $a_reset_scheduled_activation=true, $a_lang="-")
write activation status
static _lookupActive($a_id, $a_parent_type, $a_check_scheduled_activation=false, $a_lang="-")
lookup activation status
static resetTries($a_q_id, $a_user_id)
Reset tries.
static unlock($a_q_id, $a_user_id)
Reset tries.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
static getPluginObject($a_ctype, $a_cname, $a_slot_id, $a_pname)
Get Plugin Object.
tree explorer lm public area
This class represents an option in a radio group.
static set($a_var, $a_val)
Set a value.
static get($a_var)
Get a value.
Class ilStructureObjectGUI.
special template class to simplify handling of ITX/PEAR
This class represents a text area property in a property form.
This class represents a text property in a property form.
Tree class data representation in hierachical trees using the Nested Set Model with Gaps by Joe Celco...
static appendUrlParameterString($a_url, $a_par, $xml_style=false)
append URL parameter string ("par1=value1&par2=value2...") to given URL string
static getImageTagByType($a_type, $a_path, $a_big=false)
Builds an html image tag TODO: function still in use, but in future use getImagePath and move HTML-Co...
static getStyleSheetLocation($mode="output", $a_css_name="", $a_css_location="")
get full style sheet file name (path inclusive) of current user
static redirect($a_script)
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
static img($a_src, $a_alt=null, $a_width="", $a_height="", $a_border=0, $a_id="", $a_class="")
Build img tag.
static deliverFile( $a_file, $a_filename, $a_mime='', $isInline=false, $removeAfterDelivery=false, $a_exit_after=true)
deliver file for download via browser.
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
static formSelect( $selected, $varname, $options, $multiple=false, $direct_text=false, $size="0", $style_class="", $attribs="", $disabled=false)
Builds a select form field with options and shows the selected option first.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
static stripSlashesArray($a_arr, $a_strip_html=true, $a_allow="")
Strip slashes from array.
for( $i=6;$i< 13;$i++) for($i=1; $i< 13; $i++) $d
interface ilLinkCheckerGUIRowHandling
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc