1
我使用以前的發佈中的以下代碼來檢測(大部分)屬性爲「contenteditable」的元素的更改。但可悲的是它不包括改變使用的瀏覽器(Firefox)contenteditable:使用行/列修飾符時檢測元素更改
$('[contenteditable]').live('focus', function() {
var $this = $(this);
$this.data('before', $this.html());
return $this;
}).live('blur keyup paste', function() {
var $this = $(this);
if ($this.data('before') !== $this.html()) {
$this.data('before', $this.html());
$this.trigger('change');
}
return $this;
});
我怎樣才能改變這種代碼所提供的錶行/列修改控件時,包括通過強加的變化的檢測發生的表瀏覽器控件?