Home > Back-end >  Summernote rich text editor how the rich text editor to Java background database inside the content
Summernote rich text editor how the rich text editor to Java background database inside the content

Time:12-01

Page USES Summernote rich text editor in the rich text editor can upload pictures to upload audio content can also be typeset want to put all the inside of the rich text editor to edit the content (including format) to the background database,


Java background how to accept all the inside of the rich text editor content
For specific methods and examples of reference

CodePudding user response:

reference 1st floor XinMu _X response:
your problem solved, recently met the same problem, just want a simple method to solve:





The above as the summernote framework, the following is the form of a field, I hide out, need to put the content of the summernote TpInfoForm infoContect field

Can get in js submitted and give content

Var markupStr=$(' # summernote). Summernote (' code ')
Document. The getElementById (' infoTitle). value=https://bbs.csdn.net/topics/markupStr;

The hope can help you ~

Var markupStr=$(' # summernote). Summernote (' code ')
Document. The getElementById (' infoTitle). value=https://bbs.csdn.net/topics/markupStr;

The infoTitle here is modified to infoContect

CodePudding user response:

Agree with the upstairs, direct access to the contents of the rich text and then assign a value to a hidden input, along with the form submitted to the background with respect to ok, rich text is the content in the HTML element, so check when can also take style to show.

CodePudding user response:

refer to the second floor XinMu _X response:
Quote: refer to 1st floor XinMu _X response:
your problem solved, recently met the same problem, just want a simple method to solve:





The above as the summernote framework, the following is the form of a field, I hide out, need to put the content of the summernote TpInfoForm infoContect field

Can get in js submitted and give content

Var markupStr=$(' # summernote). Summernote (' code ')
Document. The getElementById (' infoTitle). value=https://bbs.csdn.net/topics/markupStr;

The hope can help you ~

Var markupStr=$(' # summernote). Summernote (' code ')
Document. The getElementById (' infoTitle). value=https://bbs.csdn.net/topics/markupStr;

The infoTitle here is modified to infoContect

??????

CodePudding user response:

refer to "the other shore flower reply: 3/f
agree with upstairs, direct access to the rich content of the text and then assign a value to a hidden input, along with the form submitted to the background with respect to ok, rich text is the content in the HTML element, so I could check when will take style to show.
well it works
  • Related