Home > Web Front-end > JS Tutorial > JQuery text changes trigger events such as focus events and out-of-focus events_jquery

JQuery text changes trigger events such as focus events and out-of-focus events_jquery

WBOY
Release: 2016-05-16 17:03:43
Original
1371 people have browsed it

Focus event in Juery:

Copy code The code is as follows:

$("#id") .focus(function(){
});

Out of focus event:
Copy code The code is as follows:

$("#id").blur(function(){
});

But the text change event cannot be like this Write:
Copy code The code is as follows:

$("#id").change( function(){
});

The text change event can be written like this, propertychange is an event triggered when the property changes
Copy code The code is as follows:

$("#id").bind("propertychange",function() {
});
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template