I have a few draggable objects which I would like the user to drag around and then press "save" and return to the page the next day to drag them some more. The draggable objects include dynamic html with event handlers etc.
我想将这些物件存储在 DB 中, 然后重新装入它们 。
实现这一目标的好办法是什么?
我提出的一种可能办法是将所有 DOM 代码存储在容器 div 中,作为字符串保存在 DB 中,然后插入到页面中,运行脚本,为具体元素添加新的事件处理器...