Is it possible to append html tags from a content-editable div to another div? I wanted to make an html editor, and I wanted to make automatic preview.
Here is the jsfiddle code: https://jsfiddle.net/eqw8L4to/12/
And here is the js code where I tried getting html tags from .html, and tried appending it to .result:
$(document).ready(function() {
$(".html").keydown(function(event) {
var x = event.keyCode
if (x == 27 && event.ctrlKey) {
$(".result").html("")
var y = $(".html").html()
$(".result").append(y)
}
})
})

