tinyMCE jQuery form validation

13,898

The following stackoverflow questions should help you on that issue:

Share:
13,898
el_pup_le
Author by

el_pup_le

ಠ_ಠ

Updated on June 04, 2022

Comments

  • el_pup_le
    el_pup_le almost 2 years

    I'm trying to use tinymce's getContent() to make a custom validation rule, how can I do this with jquery validation? I need to apply the rule to a textarea formatted with tinymce.

    Validation: http://bassistance.de/jquery-plugins/jquery-plugin-validation/

    $("#element").click( function(e) {
    
        console.log(tinyMCE.activeEditor.getContent());
    
        $("#someForm").validate({
            rules: {        
                title: {
                    required: true
                }
            }
        });
    
    });
    

    I'm thinking of just using a little bit of javascript with getContent() because it looks like there's just as much effort creating a workaround to get jquery validation working with tinymce. Thoughts on possible solutions?