Saving Contenteditable Data Using Jquery
I'm trying to save a contenteditable div's data locally with jQuery. Here is whatever I've done: link Please help me I'm stuck on this!
Solution 1:
Change the "textarea" element to "div" and add contenteditable="true". Then change text.value to text.innerHTML. Is that what you mean? It seems to work for me at this link.
<div id="editor" contentEditable="true" placeholder="Start writing..."></div>
...
[text.innerHTML || text.placeholder], {
...
session.text = text.innerHTML;
Post a Comment for "Saving Contenteditable Data Using Jquery"