[英]Save Data fromTinyMCE to php using ajax
我在应用程序中使用TinyMCE
我想使用Ajax保存在TinyMCE中输入的数据到PHP
我试过使用tinyMCE.triggerSave()
然后发送给ajax,但是当某些表情符号 添加图像后,我得到了[img] link for image [/img]
完成了该html,当在浏览器中以html输出时,这种类型的编码是否正确?
我如何将数据另存为html到db
我的剧本
tinymce.init({
selector:'textarea#chat_message',
theme: "modern",
menubar: false,
width:900,
height:100,
statusbar: false,
plugins: [
"save advlist autolink lists link image charmap print preview anchor",
"searchreplace spellchecker visualblocks code fullscreen",
"insertdatetime media table contextmenu paste emoticons bbcode anchor lists"
],
toolbar:" save bold italic | bullist numlist outdent indent | autolink | link | image | lists | charmap | anchor | spellchecker | wordcount visualblocks | visualchars | table | directionality | emoticons | paste | spellchecker | bbcode | code |",
entity_encoding: 'raw'
});
$("#chat_message").html()
将为您提供实际的内容(不剥离html标签)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.