푸

추가한 필드에 에디터를 적용하고 싶습니다.

추가한 필드에 에디터를 적용할려고 합니다
에디터는 보이는데 DB에 저장이 안되네요
검색해봐도 내용이 없어서 글 남깁니다.


아래는 수정한 내용 입니다.

write.skin.php

if ($is_dhtml_editor) {
include_once("$g4[path]/lib/cheditor4.lib.php");
echo "<script src='$g4[cheditor4_path]/cheditor.js'></script>";
echo cheditor1('wr_content', '100%', '250');
echo cheditor1('wr_5', '100%', '120');
echo cheditor1('wr_6', '100%', '120');
}
?>

<tr>
<td class=write_head style='padding-left:20px;'>연구목적</td>
<td style='padding:5 0 5 0;'>
<? if ($is_dhtml_editor) { ?>
<?=cheditor2('wr_5', $write[wr_5]);?>
<? } else { ?>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td width=50% align=left valign=bottom>
<span style="cursor: pointer;" onclick="textarea_decrease('wr_5', 10);">
<img src="<?=$board_skin_path?>/img/up.gif"></span>
<span style="cursor: pointer;" onclick="textarea_original('wr_5', 10);">
<img src="<?=$board_skin_path?>/img/start.gif"></span>
<span style="cursor: pointer;" onclick="textarea_increase('wr_5', 10);">
<img src="<?=$board_skin_path?>/img/down.gif"></span></td>
<td width=50% align=right><? if ($write_min || $write_max) { ?><span id=char_count></span>글자<?}?></td>
</tr>
</table>
<textarea id="wr_5" name="wr_5" class=tx style='width:100%; word-break:break-all;' rows=10 itemname="연구목적" required
<? if ($write_min || $write_max) { ?>onkeyup="check_byte('wr_5', 'char_count');"<?}?>><?=$write[wr_5]?></textarea>
<? if ($write_min || $write_max) { ?><script language="javascript"> check_byte('wr_5', 'char_count'); </script><?}?>
<? } ?>
</td>

</tr>
<tr><td colspan=2 height=1 bgcolor=#dddddd></td></tr>


<tr>
<td class=write_head style='padding-left:20px;'>연구내용</td>
<td style='padding:5 0 5 0;'>
<? if ($is_dhtml_editor) { ?>
<?=cheditor2('wr_content', $content);?>
<? } else { ?>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td width=50% align=left valign=bottom>
<span style="cursor: pointer;" onclick="textarea_decrease('wr_content', 10);"><img src="<?=$board_skin_path?>/img/up.gif"></span>
<span style="cursor: pointer;" onclick="textarea_original('wr_content', 10);"><img src="<?=$board_skin_path?>/img/start.gif"></span>
<span style="cursor: pointer;" onclick="textarea_increase('wr_content', 10);"><img src="<?=$board_skin_path?>/img/down.gif"></span></td>
<td width=50% align=right><? if ($write_min || $write_max) { ?><span id=char_count></span>글자<?}?></td>
</tr>
</table>
<textarea id="wr_content" name="wr_content" class=tx style='width:100%; word-break:break-all;' rows=10 itemname="내용" required
<? if ($write_min || $write_max) { ?>onkeyup="check_byte('wr_content', 'char_count');"<?}?>><?=$content?></textarea>
<? if ($write_min || $write_max) { ?><script language="javascript"> check_byte('wr_content', 'char_count'); </script><?}?>
<? } ?>
</td>
</tr>
<tr><td colspan=2 height=1 bgcolor=#dddddd></td></tr>

<tr>
<td class=write_head style='padding-left:20px;'>활용계획</td>
<td style='padding:5 0 5 0;'>
<? if ($is_dhtml_editor) { ?>
<?=cheditor2('wr_6', $write[wr_6]);?>
<? } else { ?>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td width=50% align=left valign=bottom>
<span style="cursor: pointer;" onclick="textarea_decrease('wr_6', 10);">
<img src="<?=$board_skin_path?>/img/up.gif"></span>
<span style="cursor: pointer;" onclick="textarea_original('wr_6', 10);">
<img src="<?=$board_skin_path?>/img/start.gif"></span>
<span style="cursor: pointer;" onclick="textarea_increase('wr_6', 10);">
<img src="<?=$board_skin_path?>/img/down.gif"></span></td>
<td width=50% align=right><? if ($write_min || $write_max) { ?><span id=char_count></span>글자<?}?></td>
</tr>
</table>
<textarea id="wr_6" name="wr_6" class=tx style='width:100%; word-break:break-all;' rows=10 itemname="활용계획" required
<? if ($write_min || $write_max) { ?>onkeyup="check_byte('wr_6', 'char_count');"<?}?>><?=$write[wr_6]?></textarea>
<? if ($write_min || $write_max) { ?><script language="javascript"> check_byte('wr_6', 'char_count'); </script><?}?>
<? } ?>
</td>

</tr>
<tr><td colspan=2 height=1 bgcolor=#dddddd></td></tr>

댓글 2개

하단 스크립트 부분에

if ($is_dhtml_editor) echo cheditor3('wr_content'); //이라인 처럼 추가 하세요

if ($is_dhtml_editor) echo cheditor3('wr_5');
if ($is_dhtml_editor) echo cheditor3('wr_6');
아 그렇군요
정말 감사합니다.
잘 되네요 ^^
댓글을 작성하시려면 로그인이 필요합니다.

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기 기존 게시물은 열람만 가능합니다.

+
제목 글쓴이 날짜 조회
08-12-23 조회 987
08-12-23 조회 875
08-12-23 조회 1,034
08-12-23 조회 1,090
08-12-23 조회 837
08-12-23 조회 1,070
08-12-23 조회 1,755
08-12-23 조회 816
08-12-23 조회 1,104
08-12-23 조회 1,612
08-12-23 조회 833
08-12-23 조회 1,152
08-12-23 조회 1,044
08-12-23 조회 1,321
08-12-23 조회 2,946
08-12-23 조회 913
08-12-22 조회 833
08-12-22 조회 3,830
08-12-22 조회 1,042
08-12-22 조회 1,221