I am using the WYSIWYG Editor summernote.
I have a textarea
<textarea name="data[Text][text]" rows="3" class="form-control" autofocus="autofocus" cols="30" id="TextText" required="required"></textarea>
and a javascript:
$(document).ready(function() {
$('#TextText').summernote({
height: 250,
toolbar: [
['style', ['bold', 'italic', 'underline', ]],
['para', ['ul', 'ol', 'paragraph']],
]
});
});
As you can see the the textarea has the attribute required, but after I apply the summernote to the textarea, submitting an empty form throws a javascript message in chrome :
An invalid form control with name='data[Text][text]' is not focusable.
Firefox does not throw any error but also doesn't indicate that the input is required.
How can I force summernote to keep the required attribute?