24 require_once
"./Services/Object/classes/class.ilObject.php";
44 public function __construct($a_id = 0, $a_call_by_reference =
true)
48 $this->lng = $DIC->language();
49 include_once
"./Services/Administration/classes/class.ilSetting.php";
50 $this->setting =
new ilSetting(
"advanced_editing");
52 parent::__construct($a_id, $a_call_by_reference);
79 public function delete()
82 if (!parent::delete()) {
102 include_once
"./Services/Administration/classes/class.ilSetting.php";
104 $tags =
$setting->get(
"advanced_editing_used_html_tags_" . $a_module);
106 $usedtags = unserialize(
$tags);
108 if ($a_module ==
'frm_post' || $a_module ==
'exc_ass') {
162 if ($a_module ===
'frm_post') {
163 if (!in_array(
'div', $usedtags)) {
167 if (!in_array(
'blockquote', $usedtags)) {
168 $usedtags[] =
'blockquote';
202 include_once
"./Services/Administration/classes/class.ilSetting.php";
204 $js =
$setting->get(
"advanced_editing_javascript_editor");
217 include_once
"./Services/Administration/classes/class.ilSetting.php";
219 $setting->set(
"advanced_editing_javascript_editor", $a_js_editor);
236 if (strlen($a_module)) {
237 $auto_added_tags = array();
240 if ($a_module ==
'frm_post') {
241 if (!in_array(
'div', $a_html_tags)) {
242 $auto_added_tags[] =
'div';
245 if (!in_array(
'blockquote', $a_html_tags)) {
246 $auto_added_tags[] =
'blockquote';
250 include_once
"./Services/Administration/classes/class.ilSetting.php";
252 $setting->set(
"advanced_editing_used_html_tags_" . $a_module, serialize(array_merge((array) $a_html_tags, $auto_added_tags)));
254 if (count($auto_added_tags)) {
255 require_once
'Services/AdvancedEditing/exceptions/class.ilAdvancedEditingRequiredTagsException.php';
258 $lng->txt(
'advanced_editing_required_tags'),
259 implode(
', ', $auto_added_tags)
432 $ilUser->writePref(
"show_rte", $a_state);
448 if (strlen(
$ilUser->getPref(
"show_rte")) > 0) {
449 return $ilUser->getPref(
"show_rte");
static _getUsedHTMLTagsAsString($a_module="")
Returns a string of all allowed HTML tags for text editing.
static _getRichTextEditor()
Returns the identifier for the Rich Text Editor.
static _getAllHTMLTags()
Returns an array of all possible HTML tags for text editing.
setUsedHTMLTags($a_html_tags, $a_module)
Writes an array with allowed HTML tags to the ILIAS settings.
update()
update object data
static _getUsedHTMLTags($a_module="")
Returns an array of all allowed HTML tags for text editing.
static _setRichTextEditorUserState($a_state)
Sets the state of the rich text editor visibility for the current user.
update($pash, $contents, Config $config)
& getHTMLTags()
Returns an array of all possible HTML tags for text editing.
Class ilObjAdvancedEditing.
setRichTextEditor($a_js_editor)
Sets wheather a Rich Text Editor should be used or not.
static _getRichTextEditorUserState()
Gets the state of the rich text editor visibility for the current user.
__construct($a_id=0, $a_call_by_reference=true)
Constructor public.
if(function_exists('posix_getuid') &&posix_getuid()===0) if(!array_key_exists('t', $options)) $tag