1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75:
<?php
class ContentFormattingConfig extends AbstractConfigData
{
const DEFAULT_EDITOR = 'default_editor';
const FORBIDDEN_TAGS = 'forbidden_tags';
const HTML_TAG_AUTH = 'html_tag_auth';
public function get_default_editor()
{
return $this->get_property(self::DEFAULT_EDITOR);
}
public function set_default_editor($editor)
{
$this->set_property(self::DEFAULT_EDITOR, $editor);
}
public function get_forbidden_tags()
{
return $this->get_property(self::FORBIDDEN_TAGS);
}
public function set_forbidden_tags(array $forbidden_tags)
{
$this->set_property(self::FORBIDDEN_TAGS, $forbidden_tags);
}
public function get_html_tag_auth()
{
return $this->get_property(self::HTML_TAG_AUTH);
}
public function set_html_tag_auth(array $auth)
{
$this->set_property(self::HTML_TAG_AUTH, $auth);
}
protected function get_default_values()
{
return array(
self::DEFAULT_EDITOR => 'BBCode',
self::FORBIDDEN_TAGS => array(),
self::HTML_TAG_AUTH => array()
);
}
public static function load()
{
return ConfigManager::load(__CLASS__, 'kernel', 'content-formatting');
}
public static function save()
{
ConfigManager::save('kernel', self::load(), 'content-formatting');
}
}
?>