Help getContents
See original GitHub issueHi, @JiHong88 Editor very good
I used editor.getContents();
to validators to get text values to receive notifications, but in this case it gets the whole code of textarea instead of key text.
Only get text, is there any method to do that, I’m using formvalidation.
Take a look at the code and look through the link below for info.
Thanks in advance.
"post[content2]": {
validators: {
callback: {
message: 'The contents must be between 5 and 2000 characters long',
callback: function(value) {
// Get the plain text without HTML
const text = editor.getContents({
//format: 'text'
});
return text.length <= 2000 && text.length >= 5;
}
}
}
}
Issue Analytics
- State:
- Created 3 years ago
- Comments:15 (8 by maintainers)
Top Results From Across the Web
NetSuite Applications Suite - File.getContents()
//Add additional code ... var fileObj = file.load({ id: 145 }); if (fileObj.size < 10485760){ fileObj.getContents(); } ... //Add additional code ...
Read more >GetContents Method (ConsoleWindow) - Micro Focus
Returns the contents of the console. Syntax. lsContents = consoleWindow .GetContents ([ sItemIdentifier ]). Variable, Description ...
Read more >getContents (NotesStream - JavaScript)
Represents a stream of binary or character data. The stream can be associated with a file. getContents (NotesStream - JavaScript™). Copies stream contents...
Read more >GetContent - Amazon Connect Wisdom - AWS Documentation
Retrieves content, including a pre-signed URL to download the content.
Read more >Help getContents · Issue #435 · JiHong88/suneditor - GitHub
I used editor.getContents(); to validators to get text values to receive notifications, but in this case it gets the whole code of textarea ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
they only work on github or gitee, you need to report to the website vendors that they operate, cssscript also needs to report, they are long-standing websites or large storage places for code and they will stop working action. What worries me is that they bring viruses into these software, if that is very dangerous, we do not know what their purpose is. I have downloaded it and have deleted it now.
The 2.31.1 version has been updated. If this issue has not been resolved, please reopen this issue. Thank you.
PS: The lack of other attributes in editor is that something is wrong.