textarea 에디터 미리보기에서 오류가 발생되는 문제 수정

This commit is contained in:
conory 2017-07-15 21:10:04 +09:00
parent 77418672bb
commit 56d62a816f
5 changed files with 61 additions and 12 deletions

View file

@ -61,11 +61,21 @@ class documentView extends document
return new Object(-1, 'msg_invalid_request');
}
$content = Context::get('content');
if(Context::get('logged_info')->is_admin != 'Y')
{
Context::set('content', removeHackTag(Context::get('content')));
$content = removeHackTag($content);
}
// Editor converter
$obj = new stdClass;
$obj->content = $content;
$obj->module_srl = getModel('module')->getModuleInfoByMid(Context::get('mid'))->module_srl;
$content = getModel('editor')->converter($obj, 'document');
Context::set('content', $content);
$this->setTemplatePath($this->module_path.'tpl');
$this->setTemplateFile('preview_page');
Context::set('layout', 'none');