summernote-ext-highlight
summernote-ext-highlight copied to clipboard
summernote method doesnt exist
when click the preview button I getting :
looking through https://github.com/summernote/summernote/blob/develop/examples/textarea.html line26 - $('.summernote').summernote('code')
your example code :
$('.preview-btn').click(function () { $('#preview-box').html($('.summernote').code()); $('.summernote').code(''); prettyPrint(); });
modified code :
$('.preview-btn').click(function () { $('#preview-box').html($('.summernote').summernote('code')); $('.summernote').val(''); prettyPrint(); });
working, is buggy when inserting HTML code...
@pipiscrew please use
$('#summernote').summernote('code');