ueditor使用,非常方便,百度也给了使用说明
引入
<script type="text/javascript" charset="utf-8" src="ueditor.config.js"></script>
<script type="text/javascript" charset="utf-8" src="ueditor.all.min.js"> </script>
<script type="text/javascript" charset="utf-8" src="lang/zh-cn/zh-cn.js"></script>
1.2)<body>
<div>
<h1>完整demo</h1>
<script id="editor" type="text/plain" style="width:1024px;height:500px;"></script>
</div>
1.3)
<script type="text/javascript">
var ue = UE.getEditor('editor');
</script>
1.4)ueditor.config.js 配置 toolbar的显示项
1.5),elementPathEnabled:false 元素路径 ,wordCount:false 字数统计 元素路径
1.6)var ue = UE.getEditor('editor');
ue.addListener("contentChange",function(){
writeCookieValue();
}); 增加ueditor的内容改变动作