답변 2개
채택된 답변
+20 포인트
마르스컴퍼니
Expert
7년 전
로그인 후 평가할 수 있습니다
답변에 대한 댓글 3개
�
덱
7년 전
�
마르스컴퍼니
7년 전
그누보드 데모 사이트의 글쓰기 페이지 URL
: http://demo.sir.kr/gnuboard5/bbs/write.php?bo_table=test22323
에서 소스보기를 하시면, view-source:http://demo.sir.kr/gnuboard5/bbs/write.php?bo_table=test22323
279 Line 에
<script>var g5_editor_url = "http://demo.sir.kr/gnuboard5/plugin/editor/smarteditor2", oEditors = [], ed_nonce = "XFtLPbLC2N|1531823164|806a0b295be1e2cfcc7fc9578095a9b2f8550212";</script>
라고 나옵니다. 이 이후 코드부터는 oEditors 가 쓰일 수 있습니다.
저 코드는 write.skin.php 파일에서 <?php echo $editor_html; ?> 에서 출력되는 부분입니다.
또 아래에,
function fwrite_submit(f) {
안에
<?php echo $editor_js;
도 소스보기로 확인해보면,
oEditors 로 내용이 입력되어있는지 필수체크를 하고 있는 것을 확인하실 수 있습니다.
그리고 예제의 contents 는 wr_content 로 바꾸어주면 됩니다.
oEditors.getById["contents"].exec("PASTE_HTML", [내용]);
->
oEditors.getById["wr_content"].exec("PASTE_HTML", [내용]);
: http://demo.sir.kr/gnuboard5/bbs/write.php?bo_table=test22323
에서 소스보기를 하시면, view-source:http://demo.sir.kr/gnuboard5/bbs/write.php?bo_table=test22323
279 Line 에
<script>var g5_editor_url = "http://demo.sir.kr/gnuboard5/plugin/editor/smarteditor2", oEditors = [], ed_nonce = "XFtLPbLC2N|1531823164|806a0b295be1e2cfcc7fc9578095a9b2f8550212";</script>
라고 나옵니다. 이 이후 코드부터는 oEditors 가 쓰일 수 있습니다.
저 코드는 write.skin.php 파일에서 <?php echo $editor_html; ?> 에서 출력되는 부분입니다.
또 아래에,
function fwrite_submit(f) {
안에
<?php echo $editor_js;
도 소스보기로 확인해보면,
oEditors 로 내용이 입력되어있는지 필수체크를 하고 있는 것을 확인하실 수 있습니다.
그리고 예제의 contents 는 wr_content 로 바꾸어주면 됩니다.
oEditors.getById["contents"].exec("PASTE_HTML", [내용]);
->
oEditors.getById["wr_content"].exec("PASTE_HTML", [내용]);
�
덱
7년 전
상세한 답변감사합니다. 덕분에 잘 해결했습니다!
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인
콘솔에서 Ctrl+Space를 눌러서 사용가능한 객체 목록을 보면 에디터와 관련있을만한 것들이 없습니다..ㅠ