我想要添加一个Id到正在使用时序mce实例编辑的元素。有什么办法吗?
发布于 2010-07-08 15:01:56
是的,有一种方法。您需要获取选择父节点,并在其中应用属性id:
ed.onDesiredEvent.add(function(editor, event) {
node = editor.selection.getNode();
node.setAttribute('id','the_id_to_be_assigned');
}https://stackoverflow.com/questions/3200896
复制相似问题