23include_once(
"./Services/Object/classes/class.ilObjectGUI.php");
 
   44        public function __construct($a_data, $a_id, $a_call_by_reference = 
true, $a_prepare_output = 
true)
 
   49                parent::ilObjectGUI($a_data, $a_id, $a_call_by_reference, $a_prepare_output);
 
   52                $this->lng->loadLanguageModule(
"meta");
 
   63                global $rbacsystem,
$ilErr,$ilAccess;
 
   65                $next_class = $this->ctrl->getNextClass($this);
 
   66                $cmd = $this->ctrl->getCmd();
 
   70                if(!$ilAccess->checkAccess(
'read',
'',$this->object->getRefId()))
 
   72                        $ilErr->raiseError($this->lng->txt(
'no_permission'),
$ilErr->WARNING);
 
   77                        case 'iladvancedmdsettingsgui':
 
   78                                $this->tabs_gui->setTabActive(
'md_advanced');
 
   79                                include_once(
'Services/AdvancedMetaData/classes/class.ilAdvancedMDSettingsGUI.php');
 
   81                                $ret = $this->ctrl->forwardCommand($adv_md);
 
   84                        case 'ilpermissiongui':
 
   85                                $this->tabs_gui->setTabActive(
'perm_settings');
 
   86                                include_once(
"Services/AccessControl/classes/class.ilPermissionGUI.php");
 
   88                                $ret =& $this->ctrl->forwardCommand($perm_gui);
 
   95                                        $cmd = 
"showGeneralSettings";
 
  112                global $rbacsystem, $ilAccess;
 
  114                if ($rbacsystem->checkAccess(
"visible,read",$this->object->getRefId()))
 
  116                        $this->tabs_gui->addTarget(
"md_general_settings",
 
  117                                $this->ctrl->getLinkTarget($this, 
"showGeneralSettings"),
 
  118                                array(
"showGeneralSettings", 
"view"));
 
  120                        $this->tabs_gui->addTarget(
"md_copyright",
 
  121                                $this->ctrl->getLinkTarget($this, 
"showCopyrightSettings"),
 
  122                                array(
"showCopyrightSettings"));
 
  124                        $this->tabs_gui->addTarget(
"md_advanced",
 
  125                                $this->ctrl->getLinkTargetByClass(
'iladvancedmdsettingsgui', 
""),
 
  127                                'iladvancedmdsettingsgui');
 
  131                if ($rbacsystem->checkAccess(
'edit_permission',$this->object->getRefId()))
 
  133                        $this->tabs_gui->addTarget(
"perm_settings",
 
  134                                $this->ctrl->getLinkTargetByClass(
'ilpermissiongui',
"perm"),
 
  135                                array(),
'ilpermissiongui');
 
  147                $tpl->setContent($this->form->getHTML());
 
  159                $this->tabs_gui->setTabActive(
'md_general_settings');
 
  161                include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
 
  164                $ti = 
new ilTextInputGUI($this->lng->txt(
"md_delimiter"), 
"delimiter");
 
  165                $ti->setInfo($this->lng->txt(
"md_delimiter_info"));
 
  166                $ti->setMaxLength(1);
 
  168                $ti->setValue($this->md_settings->getDelimiter());
 
  169                $this->form->addItem($ti);
 
  171                $this->form->addCommandButton(
"saveGeneralSettings", 
$lng->txt(
"save"));
 
  172                $this->form->addCommandButton(
"showGeneralSettings", 
$lng->txt(
"cancel"));
 
  174                $this->form->setTitle(
$lng->txt(
"md_general_settings"));
 
  175                $this->form->setFormAction($this->ctrl->getFormAction($this));
 
  186                $delim = (trim(
$_POST[
'delimiter']) == 
"")
 
  188                        : trim(
$_POST[
'delimiter']);
 
  189                $this->md_settings->setDelimiter($delim);
 
  190                $this->md_settings->save();
 
  193                $ilCtrl->redirect($this, 
"showGeneralSettings");
 
  202                $this->tabs_gui->setTabActive(
'md_copyright');
 
  203                $this->tpl->addBlockFile(
'ADM_CONTENT',
'adm_content',
'tpl.settings.html',
'Services/MetaData');
 
  206                $this->tpl->setVariable(
'SETTINGS_TABLE',$this->form->getHTML());
 
  208                include_once(
"./Services/MetaData/classes/class.ilMDCopyrightTableGUI.php");
 
  210                $table_gui->setTitle($this->lng->txt(
"md_copyright_selection"));
 
  211                $table_gui->parseSelections();
 
  213                $table_gui->addCommandButton(
'addEntry',$this->lng->txt(
'add'));
 
  214                $table_gui->addMultiCommand(
"confirmDeleteEntries", $this->lng->txt(
"delete"));
 
  215                $table_gui->setSelectAllCheckbox(
"entry_id");
 
  216                $this->tpl->setVariable(
'COPYRIGHT_TABLE',$table_gui->getHTML());
 
  224                $this->md_settings->activateCopyrightSelection((
int) 
$_POST[
'active']);
 
  225                $this->md_settings->save();
 
  239                $this->ctrl->saveParameter($this,
'entry_id');
 
  241                $this->tpl->setContent($this->form->getHTML());
 
  254                $this->tpl->setContent($this->form->getHTML());
 
  268                include_once(
'Services/MetaData/classes/class.ilMDCopyrightSelectionEntry.php');
 
  274                $this->entry->setLanguage(
'en');
 
  275                $this->entry->setCopyrightAndOtherRestrictions(
true);
 
  276                $this->entry->setCosts(
false);
 
  278                if(!$this->entry->validate())
 
  298                if(!is_array(
$_POST[
'entry_id']) or !count(
$_POST[
'entry_id']))
 
  305                include_once(
'Services/Utilities/classes/class.ilConfirmationGUI.php');
 
  309                $c_gui->setFormAction($this->ctrl->getFormAction($this, 
"deleteEntries"));
 
  310                $c_gui->setHeaderText($this->lng->txt(
"md_delete_cp_sure"));
 
  311                $c_gui->setCancel($this->lng->txt(
"cancel"), 
"showCopyrightSettings");
 
  312                $c_gui->setConfirm($this->lng->txt(
"confirm"), 
"deleteEntries");
 
  314                include_once(
'Services/MetaData/classes/class.ilMDCopyrightSelectionEntry.php');
 
  317                foreach(
$_POST[
"entry_id"] as $entry_id)
 
  320                        $c_gui->addItem(
'entry_id[]',$entry_id,$entry->getTitle());
 
  322                $this->tpl->setContent($c_gui->getHTML());
 
  333                if(!is_array(
$_POST[
'entry_id']) or !count(
$_POST[
'entry_id']))
 
  340                include_once(
'Services/MetaData/classes/class.ilMDCopyrightSelectionEntry.php');
 
  341                foreach(
$_POST[
"entry_id"] as $entry_id)
 
  361                include_once(
'Services/MetaData/classes/class.ilMDCopyrightSelectionEntry.php');
 
  368                if(!$this->entry->validate())
 
  374                $this->entry->update();
 
  388                if(is_object($this->form))
 
  392                include_once(
'Services/Form/classes/class.ilPropertyFormGUI.php');
 
  394                $this->form->setFormAction($this->ctrl->getFormAction($this));
 
  395                $this->form->setTitle($this->lng->txt(
'md_copyright_settings'));
 
  396                $this->form->addCommandButton(
'saveCopyrightSettings',$this->lng->txt(
'save'));
 
  397                $this->form->addCommandButton(
'showCopyrightSettings',$this->lng->txt(
'cancel'));
 
  400                $check->setChecked($this->md_settings->isCopyrightSelectionActive());
 
  402                $check->setInfo($this->lng->txt(
'md_copyright_enable_info'));
 
  403                $this->form->addItem($check);
 
  415                if(is_object($this->form))
 
  419                if(!is_object($this->entry))
 
  421                        include_once(
'Services/MetaData/classes/class.ilMDCopyrightSelectionEntry.php');
 
  425                include_once(
'Services/Form/classes/class.ilPropertyFormGUI.php');
 
  427                $this->form->setFormAction($this->ctrl->getFormAction($this));
 
  430                $tit->setValue($this->entry->getTitle());
 
  431                $tit->setRequired(
true);
 
  433                $tit->setMaxLength(255);
 
  434                $this->form->addItem($tit);
 
  437                $des->setValue($this->entry->getDescription());
 
  439                $this->form->addItem($des);
 
  442                $cop->setValue($this->entry->getCopyright());
 
  444                $this->form->addItem($cop);
 
  449                                $this->form->setTitle($this->lng->txt(
'md_copyright_edit'));
 
  450                                $this->form->addCommandButton(
'updateEntry',$this->lng->txt(
'save'));
 
  451                                $this->form->addCommandButton(
'showCopyrightSettings',$this->lng->txt(
'cancel'));
 
  455                                $this->form->setTitle($this->lng->txt(
'md_copyright_add'));
 
  456                                $this->form->addCommandButton(
'saveEntry',$this->lng->txt(
'save'));
 
  457                                $this->form->addCommandButton(
'showCopyrightSettings',$this->lng->txt(
'cancel'));
 
  470                include_once(
'Services/MetaData/classes/class.ilMDSettings.php');
 
  481                if (ini_get(
"magic_quotes_gpc"))
 
  483                        $a_str = stripslashes($a_str);
 
Confirmation screen class.
static _getInstance()
get instance
initMDSettings()
init Md settings
executeCommand()
Execute command.
__construct($a_data, $a_id, $a_call_by_reference=true, $a_prepare_output=true)
Contructor.
editEntry()
edit one selection
showGeneralSettings()
Edit general settings.
stripSlashes($a_str)
Special function to strip slashes for copyright fields.
initCopyrightEditForm($a_mode='edit')
@access public
initSettingsForm()
@access protected
saveGeneralSettings()
Save general settings.
showCopyrightSettings()
Edit copyright settings.
updateEntry()
update one entry
confirmDeleteEntries()
confirm deletion of entries
saveEntry()
save new entry
deleteEntries()
delete entries
initGeneralSettingsForm($a_mode="edit")
Init general settings form.
saveCopyrightSettings()
Save news and external webfeeds settings.
Class ilObjectGUI Basic methods of all Output classes.
prepareOutput()
prepare output
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
This class represents a text area property in a property form.
This class represents a text property in a property form.
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
if($_REQUEST['ilias_path']) define('ILIAS_HTTP_PATH' $_REQUEST['ilias_path']