Manuel
Manuel

Reputation: 9522

tinymce trigger html validation

I'm adding html to the tinymce editor through javascipt. After adding the html I wand tinymce to validate the added html with the build in html validator against the valid_elements. Which js function to I have to call to run the validation?

Upvotes: 2

Views: 206

Answers (1)

Thariama
Thariama

Reputation: 50832

It is called mceCleanup. You need to call

ed.execCommand('mceCleanup'); // ed is the editor instance you get calling tinymce.get('your_editor_id')

Upvotes: 1

Related Questions