ecms整合tinyMCE
在e/data/html/1.php中的合适位置加上下面这段代码
<!– tinyMCE –>
<script language="javascript" type="text/javascript" src="/e/data/tiny_mce/tiny_mce.js"></script>
<script language="javascript" type="text/javascript">
tinyMCE.init({
mode : "exact",
theme : "advanced",
elements : "newstext"
});
</script>
<!– /tinyMCE –>
将http://prdownloads.sourceforge.net/tinymce/tinymce_3_0_1.zip?download的东西中的tiny_mce放在e/data下
重命名/admin/editor文件名或删除
tinyMCE使用/集成/设置/详解
http://www.cublog.cn/u/16928/showart.php?id=255585
剩下自己看看效果吧
编辑器中没有涉及到上传文件的考虑,主要是安全问题,以后慢慢考虑
先做个记号,下面是比较完整的,看看fckeditor
<!– tinyMCE –>
<script language="javascript" type="text/javascript" src="/e/admin/tiny_mce/tiny_mce.js"></script>
<script language="javascript" type="text/javascript">
tinyMCE.init({
mode : "exact",
theme : "advanced",
elements : "newstext" ,
plugins : "advimage,advlink,emotions,iespell,insertdatetime,preview,media,visualchars,xhtmlxtras,style,pagebreak,filemanager",
theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,insertdate,inserttime,|,forecolor,backcolor,|,hr,removeformat,formatselect",
theme_advanced_buttons2 : "link,unlink,image,media,|,undo,redo,cleanup,|,code,preview,styleprops,pagebreak,filemanager",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_path_location : "bottom",
extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]"
});
</script>
<!– /tinyMCE –>