Below, the editor will bring you an in-depth understanding of html form input monitoring. The editor thinks it is quite good. Now I share it with you and give you a reference. Let's take a look with the editor
Today I saw a blog post about the input incident and sorted out relevant information on a whim.
event:
function changeVal(value){ console.log($(value).val())}onchange: The onchange event will only be triggered after the content changes before and after and the focus is lost.
<input type=text value= onchange=changeVal(this)>
oninput: The oninput event will be fired when the value changes.
<input type=text value= oninput=changeVal(this)>
There is also an onpropertychange event, which has the effect similar to oninput, but is dedicated to IE! Moreover, the test did not take effect, and he looked confused. . .
Replenish:
Oninput and onpropertychange fail:
oninput event:
(1) When the value is changed in the script, it will not be triggered;
(2) It will not trigger when selecting from the browser's automatic drop-down prompt;
onpropertychange event:
When input is set to disable=true, it will not be triggered.
The above is all the contents of the in-depth understanding of the input monitoring of html form that the editor brings to you. I hope you like it~
If you want to know more game activities and game strategies, please continue to pay attention to this site. The editor of this site will bring you the best, most fun and freshest game information as soon as possible. For more exciting content, please visit the vevb game channel!