JSFIDDLE
Html Code:
<body>
<input value="123">
<button>button</button>
</body>
Js Code(using JQuery 1.2.0):
$(function(){
$("button").click(function(){
$("input").val("balabala...");
});
$("body").on("change","input",function(){
alert("change");
alert($("input").val());
});
});
Question:
At the beginning, the value of the input is "123".
When I change the text through editing by hands and click other places not the input field, the change event of the input will trigger.
However, when I click the button, which will also change the value of the input, the change event of the input will not work.
Thanks for any help.