이전 설정 유지해도 차이 없게.

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@5292 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
misol 2009-01-09 02:50:50 +00:00
parent 34819438c7
commit 759521e27a
3 changed files with 48 additions and 26 deletions

View file

@ -1,6 +1,6 @@
<!--// 기본 js/언어파일 로드 -->
<!--%import("../../tpl/js/editor_common.js")-->
<!--@if($colorset == "white_texteditor" || $colorset == "black_texteditor" || $colorset == "white_text_nohtml" || $colorset == "black_text_nohtml")-->
<!--@if($colorset == "white_texteditor" || $colorset == "black_texteditor" || $colorset == "white_text_nohtml" || $colorset == "black_text_nohtml" || $colorset == "white_text_usehtml" || $colorset == "black_text_usehtml")-->
<!--@if($colorset == "black_texteditor")-->
<!--%import("css/black.css")-->
{@ $editor_class = "black" }
@ -9,7 +9,7 @@
<!--@end-->
<!--%import("js/xe_interface.js")-->
<div class="xeTextEditor {$editor_class}">
<input type="hidden" id="htm_{$editor_sequence}" value="<!--@if($colorset == "white_text_nohtml" || $colorset == "black_text_nohtml")-->n<!--@end-->" />
<input type="hidden" id="htm_{$editor_sequence}" value="<!--@if($colorset == "white_text_nohtml" || $colorset == "black_text_nohtml")-->n<!--@end--><!--@if($colorset == "white_texteditor" || $colorset == "white_texteditor")-->br<!--@end-->" />
<textarea id="editor_{$editor_sequence}" style="height:{$editor_height}px;" cols="10" rows="10"></textarea>
</div>
<script type="text/javascript">//<![CDATA[

View file

@ -11,12 +11,14 @@ function editorStartTextarea(editor_sequence, content_key, primary_key) {
editorRelKeys[editor_sequence]["func"] = editorGetContentTextarea;
var content = obj.form[content_key].value;
if(use_html=='n') {
if(use_html) {
content = content.replace(/<br([^>]*)>/ig,"\n");
content = content.replace(/&lt;/g, "<");
content = content.replace(/&gt;/g, ">");
content = content.replace(/&quot;/g, '"');
content = content.replace(/&amp;/g, "&");
if(use_html!='br') {
content = content.replace(/&lt;/g, "<");
content = content.replace(/&gt;/g, ">");
content = content.replace(/&quot;/g, '"');
content = content.replace(/&amp;/g, "&");
}
}
obj.value = content;
}
@ -25,11 +27,13 @@ function editorGetContentTextarea(editor_sequence) {
var obj = xGetElementById('editor_'+editor_sequence);
var use_html = xGetElementById('htm_'+editor_sequence).value;
var content = obj.value.trim();
if(use_html=='n') {
content = content.replace(/&/g, "&amp;");
content = content.replace(/</g, "&lt;");
content = content.replace(/>/g, "&gt;");
content = content.replace(/\"/g, "&quot;");
if(use_html) {
if(use_html!='br') {
content = content.replace(/&/g, "&amp;");
content = content.replace(/</g, "&lt;");
content = content.replace(/>/g, "&gt;");
content = content.replace(/\"/g, "&quot;");
}
content = content.replace(/(\r\n|\n)/g, "<br />");
}
return content;

View file

@ -36,22 +36,40 @@
<title xml:lang="zh-TW">黑色</title>
</color>
<color name="white_texteditor">
<title xml:lang="ko">하얀색 텍스트편집기</title>
<title xml:lang="jp">White Text Editor</title>
<title xml:lang="en">White Text Editor</title>
<title xml:lang="ru">White Text Editor</title>
<title xml:lang="es">White Text Editor</title>
<title xml:lang="zh-CN">White Text Editor</title>
<title xml:lang="zh-TW">白色文字編輯器</title>
<title xml:lang="ko">하얀색 텍스트편집기(자동 줄 바꿈)</title>
<title xml:lang="jp">White Text Editor(Auto Line Break)</title>
<title xml:lang="en">White Text Editor(Auto Line Break)</title>
<title xml:lang="ru">White Text Editor(Auto Line Break)</title>
<title xml:lang="es">White Text Editor(Auto Line Break)</title>
<title xml:lang="zh-CN">White Text Editor(Auto Line Break)</title>
<title xml:lang="zh-TW">白色文字編輯器(Auto Line Break)</title>
</color>
<color name="black_texteditor">
<title xml:lang="ko">검은색 텍스트편집기</title>
<title xml:lang="jp">Black Text Editor</title>
<title xml:lang="en">Black Text Editor</title>
<title xml:lang="ru">Black Text Editor</title>
<title xml:lang="es">Black Text Editor</title>
<title xml:lang="zh-CN">Black Text Editor</title>
<title xml:lang="zh-TW">黑色文字編輯器</title>
<title xml:lang="ko">검은색 텍스트편집기(자동 줄 바꿈)</title>
<title xml:lang="jp">Black Text Editor(Auto Line Break)</title>
<title xml:lang="en">Black Text Editor(Auto Line Break)</title>
<title xml:lang="ru">Black Text Editor(Auto Line Break)</title>
<title xml:lang="es">Black Text Editor(Auto Line Break)</title>
<title xml:lang="zh-CN">Black Text Editor(Auto Line Break)</title>
<title xml:lang="zh-TW">黑色文字編輯器(Auto Line Break)</title>
</color>
<color name="white_text_usehtml">
<title xml:lang="ko">하얀색 텍스트편집기(HTML 사용)</title>
<title xml:lang="jp">White Text Editor(Use HTML)</title>
<title xml:lang="en">White Text Editor(Use HTML)</title>
<title xml:lang="ru">White Text Editor(Use HTML)</title>
<title xml:lang="es">White Text Editor(Use HTML)</title>
<title xml:lang="zh-CN">White Text Editor(Use HTML)</title>
<title xml:lang="zh-TW">白色文字編輯器(Use HTML)</title>
</color>
<color name="black_text_usehtml">
<title xml:lang="ko">검은색 텍스트편집기(HTML 사용)</title>
<title xml:lang="jp">Black Text Editor(Use HTML)</title>
<title xml:lang="en">Black Text Editor(Use HTML)</title>
<title xml:lang="ru">Black Text Editor(Use HTML)</title>
<title xml:lang="es">Black Text Editor(Use HTML)</title>
<title xml:lang="zh-CN">Black Text Editor(Use HTML)</title>
<title xml:lang="zh-TW">黑色文字編輯器(Use HTML)</title>
</color>
<color name="white_text_nohtml">
<title xml:lang="ko">하얀색 텍스트편집기(HTML 사용 안함)</title>