這段代碼有什麼問題?我瀏覽了許多類似的問題,但找不到任何有用的東西。另一個Uncaught TypeError:undefined不是函數
$('div.editable').live('click', function() {
editEl = $(this);
$('#p-editor').hide();
$(editEl).addClass('editing');
$('#div-editor').show();
$('#div-editor textarea').val($(editEl).html());
});
Chrome開發者控制檯說:
Uncaught TypeError: undefined is not a function myJavascript.js
(anonymouse function) myJavascript.js
fire jquery-1.7.2.js
self.fireWith jquery-1.7.2.js
jQuery.extend.ready jquery-1.7.2.js
DOMContentLoaded jquery-1.7.2.js
在我看來,有些東西是未定義的。找出哪些東西是不確定的,並且你有你的答案。 –
我以爲我在用... – Maxcot
[.live(events,handler):version棄用:1.7,刪除:1.9](http://api.jquery.com/live/) – undefined