00001 <?php
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00035 require_once "class.ilObjectGUI.php";
00036
00037 class ilObjExternalToolsSettingsGUI extends ilObjectGUI
00038 {
00043 function ilObjExternalToolsSettingsGUI($a_data,$a_id,$a_call_by_reference,$a_prepare_output = true)
00044 {
00045 global $lng;
00046
00047 $this->type = "extt";
00048 $this->ilObjectGUI($a_data,$a_id,$a_call_by_reference,false);
00049
00050 define ("ILINC_DEFAULT_HTTP_PORT",80);
00051 define ("ILINC_DEFAULT_SSL_PORT",443);
00052 define ("ILINC_DEFAULT_TIMEOUT",30);
00053 $lng->loadLanguageModule("delic");
00054 $lng->loadLanguageModule("gmaps");
00055 $lng->loadLanguageModule("jsmath");
00056 }
00057
00063 function viewObject()
00064 {
00065 global $rbacsystem;
00066
00067 if (!$rbacsystem->checkAccess("visible,read",$this->object->getRefId()))
00068 {
00069 $this->ilias->raiseError($this->lng->txt("permission_denied"),$this->ilias->error_obj->MESSAGE);
00070 }
00071
00072 $this->__initSubTabs("view");
00073
00074 $this->getTemplateFile("general");
00075
00076 $this->tpl->setVariable("FORMACTION",
00077 $this->ctrl->getFormAction($this));
00078 $this->tpl->setVariable("TXT_EXTT_TITLE", $this->lng->txt("extt_title_configure"));
00079
00080 $this->tpl->setVariable("TXT_EXTT_NAME", $this->lng->txt("extt_name"));
00081 $this->tpl->setVariable("TXT_EXTT_ACTIVE", $this->lng->txt("active")."?");
00082 $this->tpl->setVariable("TXT_EXTT_DESC", $this->lng->txt("description"));
00083
00084 $this->tpl->setVariable("TXT_CONFIGURE", $this->lng->txt("extt_configure"));
00085 $this->tpl->setVariable("TXT_EXTT_REMARK", $this->lng->txt("extt_remark"));
00086
00087
00088 $this->tpl->setVariable("TXT_EXTT_ILINC_NAME", $this->lng->txt("extt_ilinc"));
00089 $this->tpl->setVariable("TXT_EXTT_ILINC_DESC", $this->lng->txt("extt_ilinc_desc"));
00090
00091
00092
00093 $icon_ok = "<img src=\"".ilUtil::getImagePath("icon_ok.gif")."\" alt=\"".$this->lng->txt("enabled")."\" title=\"".$this->lng->txt("enabled")."\" border=\"0\" vspace=\"0\"/>";
00094 $icon_not_ok = "<img src=\"".ilUtil::getImagePath("icon_not_ok.gif")."\" alt=\"".$this->lng->txt("disabled")."\" title=\"".$this->lng->txt("disabled")."\" border=\"0\" vspace=\"0\"/>";
00095
00096 $this->tpl->setVariable("EXTT_ILINC_ACTIVE", $this->ilias->getSetting('ilinc_active') ? $icon_ok : $icon_not_ok);
00097 }
00098
00099 function cancelObject()
00100 {
00101 ilUtil::sendInfo($this->lng->txt("msg_cancel"),true);
00102 $this->ctrl->redirect($this, "view");
00103 }
00104
00105 function getAdminTabs(&$tabs_gui)
00106 {
00107 $this->getTabs($tabs_gui);
00108 }
00109
00115 function getTabs(&$tabs_gui)
00116 {
00117 global $rbacsystem;
00118
00119 $this->ctrl->setParameter($this,"ref_id",$this->object->getRefId());
00120
00121 if ($rbacsystem->checkAccess("visible,read",$this->object->getRefId()))
00122 {
00123 $tabs_gui->addTarget("settings",
00124 $this->ctrl->getLinkTarget($this, "view"),
00125 array("view","editiLinc","editDelicious", "editGoogleMaps","editjsMath", ""), "", "");
00126
00127 #$tabs_gui->addTarget('ecs_server_settings',
00128 # $this->ctrl->getLinkTargetByClass('ilecssettingsgui','settings'));
00129
00130 }
00131
00132 if ($rbacsystem->checkAccess('edit_permission',$this->object->getRefId()))
00133 {
00134 $tabs_gui->addTarget("perm_settings",
00135 $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilpermissiongui'), "perm"), array("perm","info","owner"), 'ilpermissiongui');
00136 }
00137 }
00138
00144 function editiLincObject()
00145 {
00146 global $rbacsystem, $rbacreview;
00147
00148 if (!$rbacsystem->checkAccess("write",$this->object->getRefId()))
00149 {
00150 $this->ilias->raiseError($this->lng->txt("permission_denied"),$this->ilias->error_obj->MESSAGE);
00151 }
00152
00153 $this->__initSubTabs("editiLinc");
00154
00155 if ($_SESSION["error_post_vars"])
00156 {
00157 if ($_SESSION["error_post_vars"]["ilinc"]["active"] == "1")
00158 {
00159 $this->tpl->setVariable("CHK_ILINC_ACTIVE", "checked=\"checked\"");
00160 }
00161
00162 if ($_SESSION["error_post_vars"]["ilinc"]["akclassvalues_active"] == "1")
00163 {
00164 $this->tpl->setVariable("CHK_ILINC_AKCLASSVALUES_ACTIVE", "checked=\"checked\"");
00165 }
00166
00167 if ($_SESSION["error_post_vars"]["ilinc"]["akclassvalues_required"] == "1")
00168 {
00169 $this->tpl->setVariable("CHK_ILINC_AKCLASSVALUES_REQUIRED", "checked=\"checked\"");
00170 }
00171
00172 $this->tpl->setVariable("ILINC_SERVER", $_SESSION["error_post_vars"]["ilinc"]["server"]);
00173 $this->tpl->setVariable("ILINC_REGISTRAR_LOGIN", $_SESSION["error_post_vars"]["ilinc"]["registrar_login"]);
00174 $this->tpl->setVariable("ILINC_REGISTRAR_PASSWD", $_SESSION["error_post_vars"]["ilinc"]["registrar_passwd"]);
00175 $this->tpl->setVariable("ILINC_CUSTOMER_ID", $_SESSION["error_post_vars"]["ilinc"]["customer_id"]);
00176 }
00177 else
00178 {
00179
00180 $settings = $this->ilias->getAllSettings();
00181
00182 if ($settings["ilinc_active"] == "1")
00183 {
00184 $this->tpl->setVariable("CHK_ILINC_ACTIVE", "checked=\"checked\"");
00185 }
00186
00187 $this->tpl->setVariable("ILINC_SERVER", $settings["ilinc_server"].$settings["ilinc_path"]);
00188 $this->tpl->setVariable("ILINC_REGISTRAR_LOGIN", $settings["ilinc_registrar_login"]);
00189 $this->tpl->setVariable("ILINC_REGISTRAR_PASSWD", $settings["ilinc_registrar_passwd"]);
00190 $this->tpl->setVariable("ILINC_CUSTOMER_ID", $settings["ilinc_customer_id"]);
00191
00192 if (empty($settings["ilinc_port"]))
00193 {
00194 $this->tpl->setVariable("ILINC_PORT", ILINC_DEFAULT_HTTP_PORT);
00195 }
00196 else
00197 {
00198 $this->tpl->setVariable("ILINC_PORT", $settings["ilinc_port"]);
00199 }
00200
00201 if ($settings["ilinc_protocol"] == "https")
00202 {
00203 $this->tpl->setVariable("ILINC_PROTOCOL_SSL_SEL", "selected=\"selected\"");
00204 }
00205 else
00206 {
00207 $this->tpl->setVariable("ILINC_PROTOCOL_HTTP_SEL", "selected=\"selected\"");
00208 }
00209
00210 if (empty($settings["ilinc_timeout"]))
00211 {
00212 $this->tpl->setVariable("ILINC_TIMEOUT", ILINC_DEFAULT_TIMEOUT);
00213 }
00214 else
00215 {
00216 $this->tpl->setVariable("ILINC_TIMEOUT", $settings["ilinc_timeout"]);
00217 }
00218
00219 if ($settings["ilinc_akclassvalues_active"] == "1")
00220 {
00221 $this->tpl->setVariable("CHK_ILINC_AKCLASSVALUES_ACTIVE", "checked=\"checked\"");
00222 }
00223
00224 if ($settings["ilinc_akclassvalues_required"] == "1")
00225 {
00226 $this->tpl->setVariable("CHK_ILINC_AKCLASSVALUES_REQUIRED", "checked=\"checked\"");
00227 }
00228 }
00229
00230 $this->getTemplateFile("ilinc");
00231
00232 $this->tpl->setVariable("FORMACTION", $this->ctrl->getFormAction($this));
00233 $this->tpl->setVariable("TXT_ILINC_TITLE", $this->lng->txt("extt_ilinc_configure"));
00234 $this->tpl->setVariable("TXT_ILINC_ACTIVE", $this->lng->txt("extt_ilinc_enable"));
00235 $this->tpl->setVariable("TXT_ILINC_CONNECTION_DATA", $this->lng->txt("extt_ilinc_connection_data"));
00236 $this->tpl->setVariable("TXT_ILINC_ADDITIONAL_OPTIONS", $this->lng->txt("extt_ilinc_additional_options"));
00237 $this->tpl->setVariable("TXT_ILINC_SERVER", $this->lng->txt("extt_ilinc_server"));
00238 $this->tpl->setVariable("TXT_ILINC_PROTOCOL_PORT", $this->lng->txt("extt_ilinc_protocol_port"));
00239 $this->tpl->setVariable("TXT_ILINC_TIMEOUT", $this->lng->txt("extt_ilinc_timeout"));
00240 $this->tpl->setVariable("ILINC_DEFAULT_HTTP_PORT", ILINC_DEFAULT_HTTP_PORT);
00241 $this->tpl->setVariable("ILINC_DEFAULT_SSL_PORT", ILINC_DEFAULT_SSL_PORT);
00242 $this->tpl->setVariable("TXT_HTTP", $this->lng->txt('http'));
00243 $this->tpl->setVariable("TXT_SSL", $this->lng->txt('ssl'));
00244
00245 $this->tpl->setVariable("TXT_SECONDS", $this->lng->txt("seconds"));
00246 $this->tpl->setVariable("TXT_ILINC_REGISTRAR_LOGIN", $this->lng->txt("extt_ilinc_registrar_login"));
00247 $this->tpl->setVariable("TXT_ILINC_REGISTRAR_PASSWD", $this->lng->txt("extt_ilinc_registrar_passwd"));
00248 $this->tpl->setVariable("TXT_ILINC_CUSTOMER_ID", $this->lng->txt("extt_ilinc_customer_id"));
00249
00250 $this->tpl->setVariable("TXT_ILINC_AKCLASSVALUES_ACTIVE", $this->lng->txt("extt_ilinc_akclassvalues_active"));
00251 $this->tpl->setVariable("TXT_ILINC_AKCLASSVALUES_ACTIVE_INFO", $this->lng->txt("extt_ilinc_akclassvalues_active_info"));
00252 $this->tpl->setVariable("TXT_ILINC_AKCLASSVALUES_REQUIRED", $this->lng->txt("extt_ilinc_akclassvalues_required"));
00253 $this->tpl->setVariable("TXT_ILINC_AKCLASSVALUES_REQUIRED_INFO", $this->lng->txt("extt_ilinc_akclassvalues_required_info"));
00254
00255 $this->tpl->setVariable("TXT_REQUIRED_FLD", $this->lng->txt("required_field"));
00256 $this->tpl->setVariable("TXT_CANCEL", $this->lng->txt("cancel"));
00257 $this->tpl->setVariable("TXT_SUBMIT", $this->lng->txt("save"));
00258 $this->tpl->setVariable("CMD_SUBMIT", "saveiLinc");
00259 }
00260
00266 function saveiLincObject()
00267 {
00268 global $ilUser;
00269
00270
00271 if (!$_POST["ilinc"]["server"] or !$_POST["ilinc"]["port"] or !$_POST["ilinc"]["registrar_login"] or !$_POST["ilinc"]["registrar_passwd"] or !$_POST["ilinc"]["customer_id"])
00272 {
00273 $this->ilias->raiseError($this->lng->txt("fill_out_all_required_fields"),$this->ilias->error_obj->MESSAGE);
00274 }
00275
00276
00277 if ((preg_match("/^[0-9]{0,5}$/",$_POST["ilinc"]["port"])) == false)
00278 {
00279 $this->ilias->raiseError($this->lng->txt("err_invalid_port"),$this->ilias->error_obj->MESSAGE);
00280 }
00281
00282 if (substr($_POST["ilinc"]["server"],0,8) != "https://" and substr($_POST["ilinc"]["server"],0,7) != "http://")
00283 {
00284 $_POST["ilinc"]["server"] = $_POST["ilinc"]["protocol"]."://".$_POST["ilinc"]["server"];
00285 }
00286
00287 $url = parse_url($_POST["ilinc"]["server"]);
00288
00289 if (!ilUtil::isIPv4($url["host"]) and !ilUtil::isDN($url["host"]))
00290 {
00291 $this->ilias->raiseError($this->lng->txt("err_invalid_server"),$this->ilias->error_obj->MESSAGE);
00292 }
00293
00294 if (is_numeric($_POST["ilinc"]["timeout"]))
00295 {
00296 $this->ilias->setSetting("ilinc_timeout", $_POST["ilinc"]["timeout"]);
00297 }
00298
00299
00300 $this->ilias->setSetting("ilinc_server", $url["host"]);
00301 $this->ilias->setSetting("ilinc_path", $url["path"]);
00302 $this->ilias->setSetting("ilinc_protocol", $_POST["ilinc"]["protocol"]);
00303 $this->ilias->setSetting("ilinc_port", $_POST["ilinc"]["port"]);
00304 $this->ilias->setSetting("ilinc_active", $_POST["ilinc"]["active"]);
00305 $this->ilias->setSetting("ilinc_registrar_login", $_POST["ilinc"]["registrar_login"]);
00306 $this->ilias->setSetting("ilinc_registrar_passwd", $_POST["ilinc"]["registrar_passwd"]);
00307 $this->ilias->setSetting("ilinc_customer_id", $_POST["ilinc"]["customer_id"]);
00308
00309 $this->ilias->setSetting("ilinc_akclassvalues_active", $_POST["ilinc"]["akclassvalues_active"]);
00310 $this->ilias->setSetting("ilinc_akclassvalues_required", $_POST["ilinc"]["akclassvalues_required"]);
00311
00312 ilUtil::sendInfo($this->lng->txt("extt_ilinc_settings_saved"),true);
00313 $this->ctrl->redirect($this,'editiLinc');
00314 }
00315
00321 function editDeliciousObject()
00322 {
00323 global $ilAccess, $rbacreview, $lng, $ilCtrl;
00324
00325 $d_set = new ilSetting("delicious");
00326
00327 $this->getTemplateFile("delicious");
00328
00329 if (!$ilAccess->checkAccess("write", "", $this->object->getRefId()))
00330 {
00331 $this->ilias->raiseError($this->lng->txt("permission_denied"),$this->ilias->error_obj->MESSAGE);
00332 }
00333
00334 $this->__initSubTabs("editDelicious");
00335
00336 if ($d_set->get("add_info_links") == "1")
00337 {
00338 $this->tpl->setVariable("CHK_ADD_LINKS_ACTIVE", "checked=\"checked\"");
00339 }
00340
00341 if ($d_set->get("user_profile") == "1")
00342 {
00343 $this->tpl->setVariable("CHK_ADD_PROFILE_ACTIVE", "checked=\"checked\"");
00344 }
00345
00346 $this->tpl->setVariable("FORMACTION", $ilCtrl->getFormAction($this));
00347 $this->tpl->setVariable("TXT_DELICIOUS_SETTINGS", $lng->txt("delic_settings"));
00348 $this->tpl->setVariable("TXT_ADD_DELICIOUS_LINK", $lng->txt("delic_add_info_links"));
00349 $this->tpl->setVariable("TXT_ALLOW_PROFILE", $lng->txt("delic_user_profile"));
00350 $this->tpl->setVariable("TXT_CANCEL", $lng->txt("cancel"));
00351 $this->tpl->setVariable("TXT_SUBMIT", $lng->txt("save"));
00352 $this->tpl->setVariable("CMD_SUBMIT", "saveDelicious");
00353 }
00354
00355
00359 function saveDeliciousObject()
00360 {
00361 global $ilCtrl;
00362
00363 $d_set = new ilSetting("delicious");
00364
00365 $d_set->set("add_info_links", $_POST["add_info_links"]);
00366 $d_set->set("user_profile", $_POST["user_profile"]);
00367 $ilCtrl->redirect($this, "editDelicious");
00368 }
00369
00370
00376 function editjsMathObject()
00377 {
00378 global $ilAccess, $rbacreview, $lng, $ilCtrl, $tpl;
00379
00380 $jsMathSetting = new ilSetting("jsMath");
00381 $path_to_jsmath = array_key_exists("path_to_jsmath", $_GET) ? $_GET["path_to_jsmath"] : $jsMathSetting->get("path_to_jsmath");
00382
00383 if (!$ilAccess->checkAccess("write", "", $this->object->getRefId()))
00384 {
00385 $this->ilias->raiseError($this->lng->txt("permission_denied"),$this->ilias->error_obj->MESSAGE);
00386 }
00387
00388 $this->__initSubTabs("editjsMath");
00389
00390 include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
00391 $form = new ilPropertyFormGUI();
00392 $form->setFormAction($ilCtrl->getFormAction($this));
00393 $form->setTitle($lng->txt("jsmath_settings"));
00394
00395
00396 $enable = new ilCheckboxInputGUI($lng->txt("jsmath_enable_jsmath"), "enable");
00397 $enable->setChecked($jsMathSetting->get("enable"));
00398 $enable->setInfo($lng->txt("jsmath_enable_jsmath_info"));
00399 $form->addItem($enable);
00400
00401 $text_prop = new ilTextInputGUI($lng->txt("jsmath_path_to_jsmath"), "path_to_jsmath");
00402 $text_prop->setInfo($lng->txt("jsmath_path_to_jsmath_desc"));
00403 $text_prop->setValue($path_to_jsmath);
00404 $text_prop->setRequired(TRUE);
00405 $text_prop->setMaxLength(400);
00406 $text_prop->setSize(80);
00407 $form->addItem($text_prop);
00408
00409 $enable = new ilCheckboxInputGUI($lng->txt("jsmath_default_setting"), "makedefault");
00410 $enable->setChecked($jsMathSetting->get("makedefault"));
00411 $enable->setInfo($lng->txt("jsmath_default_setting_info"));
00412 $form->addItem($enable);
00413
00414 $form->addCommandButton("savejsMath", $lng->txt("save"));
00415 $form->addCommandButton("view", $lng->txt("cancel"));
00416
00417 $tpl->setVariable("ADM_CONTENT", $form->getHTML());
00418 }
00419
00423 function savejsMathObject()
00424 {
00425 global $ilCtrl;
00426 $error = FALSE;
00427
00428 $path_to_jsmath = ilUtil::stripSlashes($_POST["path_to_jsmath"]);
00429 while (strrpos($path_to_jsmath, "/") == strlen($path_to_jsmath)-1)
00430 {
00431 $path_to_jsmath = substr($path_to_jsmath, 0, strlen($path_to_jsmath)-1);
00432 }
00433
00434 if (file_exists($path_to_jsmath . "/" . "jsMath.js"))
00435 {
00436 }
00437 else
00438 {
00439 $error = TRUE;
00440 if (strlen($path_to_jsmath) == 0)
00441 {
00442 ilUtil::sendInfo($this->lng->txt("fill_out_all_required_fields"), TRUE);
00443 }
00444 else
00445 {
00446 $ilCtrl->setParameter($this, "path_to_jsmath", $path_to_jsmath);
00447 ilUtil::sendInfo($this->lng->txt("jsmath_path_not_found"), TRUE);
00448 }
00449 }
00450
00451 if (!$error)
00452 {
00453 $jsMathSetting = new ilSetting("jsMath");
00454 $jsMathSetting->set("path_to_jsmath", $path_to_jsmath);
00455 $jsMathSetting->set("enable", ilUtil::stripSlashes($_POST["enable"]));
00456 $jsMathSetting->set("makedefault", ilUtil::stripSlashes($_POST["makedefault"]));
00457 }
00458
00459 $ilCtrl->redirect($this, "editjsMath");
00460 }
00461
00467 function editGoogleMapsObject()
00468 {
00469 global $ilAccess, $rbacreview, $lng, $ilCtrl, $tpl;
00470
00471 $gm_set = new ilSetting("google_maps");
00472
00473 if (!$ilAccess->checkAccess("write", "", $this->object->getRefId()))
00474 {
00475 $this->ilias->raiseError($this->lng->txt("permission_denied"),$this->ilias->error_obj->MESSAGE);
00476 }
00477
00478 $this->__initSubTabs("editGoogleMaps");
00479
00480 $api_key = $gm_set->get("api_key");
00481 $std_latitude = $gm_set->get("std_latitude");
00482 $std_longitude = $gm_set->get("std_longitude");
00483 $std_zoom = $gm_set->get("std_zoom");
00484 $api_url = "http://www.google.com/apis/maps/signup.html";
00485
00486 include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
00487 $form = new ilPropertyFormGUI();
00488 $form->setFormAction($ilCtrl->getFormAction($this));
00489 $form->setTitle($lng->txt("gmaps_settings"));
00490
00491
00492 $enable = new ilCheckboxInputGUI($lng->txt("gmaps_enable_gmaps"), "enable");
00493 $enable->setChecked($gm_set->get("enable"));
00494 $enable->setInfo($lng->txt("gmaps_enable_gmaps_info"));
00495 $form->addItem($enable);
00496
00497
00498 $text_prop = new ilTextInputGUI($lng->txt("gmaps_api_key"), "api_key");
00499 $text_prop->setInfo($lng->txt("gmaps_api_key_desc").' <a href="'.$api_url.'">'.$api_url.'</a>');
00500 $text_prop->setValue($api_key);
00501 $text_prop->setRequired(false);
00502 $text_prop->setMaxLength(200);
00503 $text_prop->setSize(60);
00504 $form->addItem($text_prop);
00505
00506
00507 $loc_prop = new ilLocationInputGUI($lng->txt("gmaps_std_location"),
00508 "std_location");
00509 $loc_prop->setLatitude($std_latitude);
00510 $loc_prop->setLongitude($std_longitude);
00511 $loc_prop->setZoom($std_zoom);
00512 $form->addItem($loc_prop);
00513
00514 $form->addCommandButton("saveGoogleMaps", $lng->txt("save"));
00515 $form->addCommandButton("view", $lng->txt("cancel"));
00516
00517 $tpl->setVariable("ADM_CONTENT", $form->getHTML());
00518 }
00519
00520
00524 function saveGoogleMapsObject()
00525 {
00526 global $ilCtrl;
00527
00528 $gm_set = new ilSetting("google_maps");
00529
00530 $gm_set->set("enable", ilUtil::stripSlashes($_POST["enable"]));
00531 $gm_set->set("api_key", ilUtil::stripSlashes($_POST["api_key"]));
00532 $gm_set->set("std_latitude", ilUtil::stripSlashes($_POST["std_location"]["latitude"]));
00533 $gm_set->set("std_longitude", ilUtil::stripSlashes($_POST["std_location"]["longitude"]));
00534 $gm_set->set("std_zoom", ilUtil::stripSlashes($_POST["std_location"]["zoom"]));
00535
00536 $ilCtrl->redirect($this, "editGoogleMaps");
00537 }
00538
00539
00540 function __initSubTabs($a_cmd)
00541 {
00542 $ilinc = ($a_cmd == 'editiLinc') ? true : false;
00543 $overview = ($a_cmd == 'view' or $a_cmd == '') ? true : false;
00544 $delicious = ($a_cmd == 'editDelicious') ? true : false;
00545 $gmaps = ($a_cmd == 'editGoogleMaps') ? true : false;
00546 $jsmath = ($a_cmd == 'editjsMath') ? true : false;
00547
00548 $this->tabs_gui->addSubTabTarget("overview", $this->ctrl->getLinkTarget($this, "view"),
00549 "", "", "", $overview);
00550 $this->tabs_gui->addSubTabTarget("delic_extt_delicious", $this->ctrl->getLinkTarget($this, "editDelicious"),
00551 "", "", "", $delicious);
00552 $this->tabs_gui->addSubTabTarget("jsmath_extt_jsmath", $this->ctrl->getLinkTarget($this, "editjsMath"),
00553 "", "", "", $jsmath);
00554 $this->tabs_gui->addSubTabTarget("gmaps_extt_gmaps", $this->ctrl->getLinkTarget($this, "editGoogleMaps"),
00555 "", "", "", $gmaps);
00556 $this->tabs_gui->addSubTabTarget("extt_ilinc", $this->ctrl->getLinkTarget($this, "editiLinc"),
00557 "", "", "", $ilinc);
00558 }
00559
00560 function &executeCommand()
00561 {
00562
00563 $next_class = $this->ctrl->getNextClass($this);
00564 $cmd = $this->ctrl->getCmd();
00565 $this->prepareOutput();
00566
00567 switch($next_class)
00568 {
00569 case 'ilecssettingsgui':
00570 include_once('Services/WebServices/ECS/classes/class.ilECSSettingsGUI.php');
00571 $this->ctrl->forwardCommand(new ilECSSettingsGUI());
00572 $this->tabs_gui->setTabActive('ecs_server_settings');
00573 break;
00574
00575 case 'ilpermissiongui':
00576 include_once("./classes/class.ilPermissionGUI.php");
00577 $perm_gui =& new ilPermissionGUI($this);
00578 $ret =& $this->ctrl->forwardCommand($perm_gui);
00579 $this->tabs_gui->setTabActive('perm_settings');
00580 break;
00581
00582 default:
00583 $this->tabs_gui->setTabActive('settings');
00584 if(!$cmd)
00585 {
00586 $cmd = "view";
00587 }
00588 $cmd .= "Object";
00589 $this->$cmd();
00590
00591 break;
00592 }
00593 return true;
00594 }
00595
00596 }
00597 ?>