第一步:下载ueditor1.4.3
地址:http://ueditor.baidu.com/website/download.html;
第二步:把ueditor1.4.3放到public文件夹下,更名为ueditor
第三步:把ueditor1.4.3放到public文件夹下在需要引用的文件中加入
<span style="font-size:18px;"><!-- 配置文件 -->
<script type="text/javascript" src="http://localhost/neau/Public/ueditor/ueditor.config.js"></script>
<!-- 编辑器源码文件 -->
<script type="text/javascript" src="http://localhost/neau/Public/ueditor/ueditor.all.js"></script>
<!-- 实例化编辑器 -->
<script type="text/javascript">
var ue = UE.getEditor('container');
</script></span>
注意:这里要将<span style="font-size:18px;">src="http://localhost/neau/Public/ueditor/ueditor.all.js"</span>
写为绝对路径而非相对路径;
第四步:在需要显示编辑器的地方加下面的代码
<strong><span style="font-size:18px;"><span style="font-size:24px;"><strong></strong></span></span></strong><pre name="code" class="html"><span style="font-size:18px;"><!-- 编辑器容器 --></span>
<td colspan="3" class="tablebj03" > <script id="container" name="content" type="text/plain" style="width:960px;height:500px;"></script> </td>
这样就能在Thinkphp3.1上使用ueditor1.4.3了