Use the CKEditor editor to edit text and ckeditor text

Source: Internet
Author: User

Use the CKEditor editor to edit text and ckeditor text

Download CKEditor first.

: Click to open the link

Decompress the downloaded CKEditor and import it to the project.

Then introduce CKEditor on the page.

<script type="text/javascript" src="ckeditor/ckeditor.js"></script>
Add class = "ckeditor" to the textarea label to be edited and add the corresponding id and name attributes.

<textarea rows="10" cols="20" id="editor1" name="editor1" class="ckeditor"></textarea>
Then run the command on the server to use CKEditor.

Effect




Who will use the FCKeditor text editor?

Haha... It's really timely! I just used .....
First, decompress the FCKeditor 3.2 package.
In the calling file <script type = "text/javascript" src = "... ckeditor. js"> </script>, extract the package address
Insert text fields where you want to put the editor
<Textarea id = "editor" name = "content" class = "ckeditor"> </textarea>
Try...

How can I obtain the value of the text field and insert it to the database after using the ckeditor on a webpage?

Yes.
Var data = CKEDITOR. instances. Your editor id. getData ()
Submit to the background
String value = request. getParameter ("")
No matter what framework is used, it is actually the most basic getParameter encapsulation.
However, you need to encodeURI (data) first when passing the value, and then URLDecoder. decode (value, "UTF-8") in the background, otherwise there will be problems with special character transmission.
 

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.