contenteditable not working in IE 10

前端 未结 3 569
长发绾君心
长发绾君心 2021-01-04 13:35

I am trying to create client side editable table. Here is my code. It works in Chrome, Firefox but not in IE. Is there anything more to do with script for IE?



        
3条回答
  •  迷失自我
    2021-01-04 14:26

    There are many elements in IE, which can't have contenteditable set directly. However, you can wrap the whole table into a content editable div.

    ...

    This will make all the cells in the table editable. Though in some browsers (FF) the view will be a bit messy due to the shown editing handles of the table.

    Another possibility is to add for example a content editable span or div to each td.

提交回复
热议问题