Ajax How to assign the contents of the Kindeditor editor to textarea when submitting a form

Source: Internet
Author: User

Kindeditor can not get the value of the TextArea text box under Firefox or other browsers.

First, describe the Kindeditor error that I encountered here:
1, under the IE8/FF are not the value;
2, when the Click Kindeditor Full Screen button to switch to Full-screen mode input, and then return to normal mode, you can get the value;
3, I use jquery Ajax Click event Submission form, can not get the value;
4, directly with the form of the submission button can get the value.

So how to solve the above problems?

The code is as follows Copy Code

<script type= "Text/javascript" >
Kindeditor.ready (function (K) {
K.create (' <span class= ' wp_keywordlink_affiliate ' ><a href= ' textarea ' title= ') view all articles in textarea "target=" _ Blank ">textarea</a></span>[name=" content "] ', {
Themetype: ' Simple ',
Resizetype:1,
Uploadjson: ' common/keditor/upload_json.php ',
Filemanagerjson: ' common/keditor/file_manager_json.php ',
Allowfilemanager:true,
The following line of code is the key, executing This.sync () when the focus is lost, and synchronizing the input values into the textarea;
Afterblur:function () {This.sync ();}
});
});
</script>

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.