1
我需要趕在jQuery的單擊事件,這是我的HTML代碼:如何處理點擊按鈕的jQuery
<input type="button" id="aggiungiDomande" value="+">
,這是我的jQuery代碼:
$('#aggiungiDomande').on('click',function(){
alert("HI");
});
我想我wroing因爲我什麼也沒有顯示。任何人都可以幫助我?
它工作正常。如果你沒有把代碼放在'$(document).ready(function(){// code}'看到https://jsfiddle.net/harishkommuri/yb4yp29z/ – Harish
你把你的javascript代碼包裝到'$(文件)。就緒()'? – reporter