how to get sun editor value
<script>
var editor;
// If the textarea is exists then the editor will call;
document.querySelector('textarea') ? (function(){
editor = SUNEDITOR.create((document.querySelector('textarea') || '#textarea'),{
lang: SUNEDITOR_LANG['en']
});
})() : 0;
var submit = document.querySelector('button[type="submit"]');
submit.onclick = function() {
document.querySelector('textarea').value = editor.getContents();
}
</script>