下载 KindEditor 最新版本,下载以后打开 examples/index.html 就能够看到演示。php
下载页面: http://www.kindsoft.net/down.phpcss
注意:下载请使用下载工具,有事打不开网页用下载工具能够进行下载html
解压 kindeditor-x.x.x.zip 文件,将全部文件上传到您的网站程序目录里,例如:http://您的域名/editor/java
Note浏览器
您能够根据需求删除如下目录后上传到服务器。服务器
<textarea id="editor_id" name="content" style="width:700px;height:300px;"> <strong>HTML内容</strong> </textarea>
或者
<textarea name="content" style="width:800px;height:400px;visibility:hidden;">KindEditor2</textarea>
注意textarea 的name必须用content或者与下面JS代码中的'textarea[name="content"]'name值相同
Noteapp
<script charset="utf-8" src="/editor/kindeditor.js"></script> <script charset="utf-8" src="/editor/lang/zh_CN.js"></script> <script> var editor; KindEditor.ready(function(K) { editor = K.create('textarea[name="content"]', { allowFileManager : true }); }); </script>
Noteasp.net
var options = { cssPath : '/css/index.css', filterMode : true }; var editor = K.create('textarea[name="content"]', options);
上面红色部分代码--并无任何乱用
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>无标题文档</title> <script type="text/javascript" src="kindeditor-4.1.10/kindeditor-min.js"></script> <script type="text/javascript" src="kindeditor-4.1.10/lang/zh_CN.js"></script> <script> var editor; KindEditor.ready(function(K) { editor = K.create('textarea[name="content"]', { allowFileManager : true }); }); </script> </head> <body> <textarea id="editor_id" name="content" style="width:700px;height:300px;"> KindEditor1 </textarea> <textarea name="content" style="width:800px;height:400px;visibility:hidden;">KindEditor2</textarea> </body> </html>
DONEjsp