diff --git a/extend/ckeditor.extend.php b/extend/ckeditor.extend.php
index c752f5610..cad9fa117 100644
--- a/extend/ckeditor.extend.php
+++ b/extend/ckeditor.extend.php
@@ -7,4 +7,6 @@ $editor = (object)array(
'config_js' => $g4['path']."/plugin/ckeditor/config.js",
'data' => "data/editor"
);
+
+include_once($editor->lib);
?>
\ No newline at end of file
diff --git a/plugin/ckeditor/ckeditor.lib.php b/plugin/ckeditor/ckeditor.lib.php
index 2f2609403..74d9e214b 100644
--- a/plugin/ckeditor/ckeditor.lib.php
+++ b/plugin/ckeditor/ckeditor.lib.php
@@ -4,19 +4,27 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
function editor_textarea($id, $content="", $class="")
{
global $g4;
- $upload_url = $g4['path']."/plugin/ckeditor/upload.php?type=Images";
+ //$upload_url = $g4['path']."/plugin/ckeditor/upload.php?type=Images";
$str = "\n";
//$str .= "\n";
return $str;
}
+// textarea 로 값을 넘김
function editor_getdata($id)
{
- return "var {$id}_data = CKEDITOR.instances.{$id}.getData();\n";
+ if (defined('_EDITOR_'))
+ return "var {$id}_data = CKEDITOR.instances.{$id}.getData();\n";
+ else
+ return "";
}
+// textarea 의 값이 비어 있는지 검사
function editor_empty($id, $textarea_name="내용을")
{
- return "if (!{$id}_data) { alert(\"$textarea_name 입력해 주십시오.\"); return false; }\n";
+ if (defined('_EDITOR_'))
+ return "if (!{$id}_data) { alert(\"$textarea_name 입력해 주십시오.\"); return false; }\n";
+ else
+ return "";
}
?>
\ No newline at end of file