cheditor 에디터 심플하게 사용하기 > 그누4 팁자료실

그누4 팁자료실

그누보드4와 관련된 팁을 여러분들과 함께 공유하세요.
나누면 즐거움이 커집니다.

cheditor 에디터 심플하게 사용하기 정보

cheditor 에디터 심플하게 사용하기

본문

수정파일 cheditor4.lib.php

    function cheditor1($id, $width='100%', $height='250',$template_file = "template.xml")
    {
        global $g4;

        return "
        <script type='text/javascript'>
        var ed_{$id} = new cheditor('ed_{$id}');
        ed_{$id}.config.editorHeight = '{$height}';
        ed_{$id}.config.editorWidth = '{$width}';
        ed_{$id}.inputForm = 'tx_{$id}';

        ed_{$id}.templatePath = ed_{$id}.config.editorPath + '{$template_file}';
        </script>";
    }


cheditor5/template.xml 을 다른이름 으로 하나 복사 후 필요 아이콘만 남긴후 사용

simple_template.xml 복사 템플릿

에디터 사용 할때
<?=cheditor1('etc1_content', '100%', '100', 'simple_template.xml');?>


결과값 









추천
8
  • 복사

댓글 10개

© SIRSOFT
현재 페이지 제일 처음으로