模板代码

<!DOCTYPE HTML>
<html lang="en-US"> <head>
<meta charset="UTF-8">
<title>ueditor demo</title>
</head> <body>
<!-- 加载编辑器的容器 -->
<script id="container" name="content" type="text/plain"> </script>
<!-- 配置文件 -->
<script type="text/javascript" src="http://localhost/myapp/public/ueditor.config.js"></script>
<!-- 编辑器源码文件 -->
<script type="text/javascript" src="http://localhost/myapp/public/ueditor.all.js"></script>
<!-- 实例化编辑器 --> <form action="__URL__/insert" method="post" >
<textarea name="content" id="myEditor"></textarea>
<script type="text/javascript">
UE.getEditor('myEditor', {
theme:"default", //皮肤
lang:"zh-cn", //语言
initialFrameWidth:800, //初始化编辑器宽度,默认800
initialFrameHeight:320
});
</script>
<input type="submit" value="提交">
</form>
</body>
</html>

控制器代码

public function insert(){
header("Content-Type:text/html; charset=utf-8");
$Dao = M("admin");
$Dao->create();
$Dao->id='1';
$Dao->user=htmlspecialchars($_POST['content']);
$Dao->add();
print_r($Dao);
}

thinkphp整合ueditor(百度编辑器)方法

thinkphp 对百度编辑器里的内容进行保存的更多相关文章

  1. 使用Js获取和更改FCKeditor编辑器里的内容

    之前在一个系统里使用了FCKeditor编辑器,由于项目需求需要在FCKeditor里添加一个自定义的按钮用于实现自己的需求 主要是在点击该按钮时删除或添加FCKeditor编辑器里的内容 其实是一个 ...

  2. thinkphp——通过在线编辑器添加的内容在模板里正确显示(只显示内容,而不是html代码)

    thinkphp编辑器回显问题如下: 解决办法如下: 对于编辑器发布的内容,前台模板显示为html的解决办法是: 在模板输出字段加入html_entity_decode()函数 也就是:PHP输出时的 ...

  3. 解决百度编辑器ueditor插入视频网址保存不了问题

    问题:如下图,在百度编辑器中插入视频,视频网址可以识别,但是提交内容后视频却显示不了. 解决:这个问题主要是编辑器中会过滤一些html标签,所以可以给标签添加白名单. 修改 ueditor.confi ...

  4. 织梦替换百度编辑器后栏目内容、单页无法保存bug修复

    找了一些教程是错的,这个测试过是正确的. 修改后台文件dede>templets>catalog_add.htm和catalog_edit.htm 一.在catalog_add.htm大概 ...

  5. 百度编辑器前后端二开图片上传Js Thinkphp tp5 ueditor

    百度编辑器图片上传Jsueditor.all.min.js 下载链接 链接:https://pan.baidu.com/s/1VNgw9ELgRRHKeCQheFkQTw 提取码:fnfi 使用方法: ...

  6. 百度编辑器 ueditor 内容编辑自动套P标签,及p标签 替换

    如图,红框为回车键和shift+回车 :    ===>>  ueditor.all.js中: 1: 搜索修改成false:allowDivTransToP: false 再搜索并修改以下 ...

  7. thinkphp 百度编辑器和layer简单用法

    百度编辑器1.4.3.3和layer插件简单案例 :后台单页面管理 增删改查操作 此处为默认图片保存路径,如果要修改保存路径,需要修改config文件. 添加页. <extend name=&q ...

  8. Thinkphp 3.2.3配置百度编辑器(UEditor)

    Thinkphp 3.2.3配置百度编辑器(UEditor) 1.把百度编辑器放到项目的Public目录下 命名为:UEditor 2.找到thinkphp框架系统自带类中的Html.class.ph ...

  9. 百度编辑器ueditor获取不到内容?请把form放在table等其他元素最外面

    百度编辑器ueditor获取不到内容?请把form放在table等其他元素最外面. <form name="form" method="post" act ...

随机推荐

  1. [转载]java日志框架log4j详细配置及与slf4j联合使用教程

    一.log4j基本用法 首先,配置log4j的jar,maven工程配置以下依赖,非maven工程从maven仓库下载jar添加到“build path” 1 2 3 4 5 <dependen ...

  2. sql字段组合唯一

    create unique index [Itenmid_Uid] on Userchangeinfo(Itemid,Uid)

  3. C#实现RSA加密与解密、签名与认证

    一.RSA简介 RSA公钥加密算法是1977年由Ron Rivest.Adi Shamirh和LenAdleman在(美国麻省理工学院)开发的.RSA取名来自开发他们三者的名字.RSA是目前最有影响力 ...

  4. [Windows Azure] What is a cloud service?

    What is a cloud service? When you create an application and run it in Windows Azure, the code and co ...

  5. 每日英语:Tencent Fights for China's Online Shoppers

    In the war for the Chinese Internet, messaging giant Tencent is taking the battle to rival Alibaba's ...

  6. 【硅谷问道】Chris Lattner 访谈录(上)

    [硅谷问道]Chris Lattner 访谈录(上) 话题 Chris Lattner 是谁? Xcode 的编译器 LLVM 背后有怎样的故事? Swift 诞生的前世今生,封闭的苹果为何要拥抱开源 ...

  7. (装机)关于WINRE/ESP/LRS_ESP/MSR/PBR这些分区

    WINRE 1GB 用途:Windows 8 系统恢复模式.这个分区是保存是在Windows 8 系统主体本身被破坏无法正常启动的时候进行系统修复的Windows 8 PE系统.. ESP 260MB ...

  8. 【Android】事件输入系统-代码层次解读

    本文基于Android-4.0 理论层次解读 请看:www.cnblogs.com/lcw/p/3373214.html 如何管理各种驱动设备 在理论中谈到EventHub,这个一看就是一个做实事的, ...

  9. Asp.Net发送手机验证码

    C#发送手机验证码,平台有很多,我就说说其中的1个平台 测试环境:.net2.0 测试效果:速度还可以,10秒内接收短信 1.去http://www.yuntongxun.com注册,会送8元测试金额 ...

  10. ffmpeg抓屏输出的设置

    之前做windows下抓屏输出时使用ffmpeg.exe作为抓屏输出测试,命令行如下: ffmpeg -f gdigrab -i "desktop" -r 25 -vcodec m ...