PHP心得之-在kindeditor取得里面的textarea 值

WBOY
Release: 2016-06-13 12:20:26
Original
936 people have browsed it

PHP经验之-在kindeditor取得里面的textarea 值

PHP经验之-在kindeditor取得里面的textarea 值

  • |
  • 浏览:123
  • |
  • 更新:2014-05-29 12:04

有时候需要更新kindeditor 里面的值,弄了老半天里面的值也没变换好,查了下官网手册,解决办法很简单,在这个 editor 的定义后面加上这段代码就可以了··

?

afterCreate : function() {

? ? ? ? this.sync();

? ? ? ?},

? ? ? ?afterBlur:function(){

? ? ? ? ? ?this.sync();

? ? ? ?}?

?

?

例如: ?<script></script>

var editor;

var isWl = 1 ;

KindEditor.ready(function(K) {

editor = K.create('textarea', {

allowFileManager : true ,

filterMode : false ,

urlType : 'domain' ,

afterCreate : function() {

? ? ? ? this.sync();

? ? ? ?},

? ? ? ?afterBlur:function(){

? ? ? ? ? ?this.sync();

? ? ? ?} ??

});

});

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!