에디터 모듈에 HTML 허용 설정 추가

회원 모듈에도 no html 서명을 위한 옵션 추가
This commit is contained in:
conory 2017-07-13 00:46:28 +09:00
parent f7915f8204
commit da0ad3bd39
20 changed files with 179 additions and 142 deletions

View file

@ -43,7 +43,8 @@ class editorModel extends editor
}
// Fill in some other values.
if($editor_config->enable_autosave != 'N') $editor_config->enable_autosave = 'Y';
$editor_config->enable_autosave = $editor_config->enable_autosave ?: 'Y';
$editor_config->allow_html = $editor_config->allow_html ?: 'Y';
if(!is_array($editor_config->enable_html_grant)) $editor_config->enable_html_grant = array();
if(!is_array($editor_config->enable_comment_html_grant)) $editor_config->enable_comment_html_grant = array();
if(!is_array($editor_config->upload_file_grant)) $editor_config->upload_file_grant = array();
@ -252,6 +253,9 @@ class editorModel extends editor
}
Context::set('enable_autosave', $option->enable_autosave);
// Set allow html
Context::set('allow_html', ($option->allow_html === false || $option->allow_html === 'N') ? false : true);
// Load editor components.
$site_srl = Context::get('site_module_info')->site_srl ?: 0;
if($option->editor_skin === 'dreditor')