Skip to content
Advertisement

Copy and Paste Table Using ContentEditable

This video is a good representation of the issue I am facing: https://drive.google.com/file/d/1jN44lUpnbVDv_m3LuPhlJl6RFUu884jz/view. I cannot copy and paste a table from another a tab without it breaking down. Because this uses local storage, here is a JSFiddle: https://jsfiddle.net/znj537w0/1/.

JavaScript
JavaScript
JavaScript

Advertisement

Answer

Use this:

JavaScript

Change innerText to innerHTML. https://jsfiddle.net/3uvfjdew/

User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement