HTML tutorial
CSS3 tutorial
Bootstrap tutorial
JavaScript tutorial
JQuery tutorial
AngularJS tutorial
React tutorial
NodeJS tutorial
PHP tutorial
Python tutorial
Python3 tutorial
Django tutorial
Linux tutorial
Docker tutorial
Ruby tutorial
Java tutorial
C tutorial
C ++ tutorial
Perl tutorial
JSP tutorial
Lua tutorial
Scala tutorial
Go tutorial
ASP.NET tutorial
C # tutorial
jQuery Event Methods : Set background color of a <div> element when the <div> element or any child elements get focus
The focusin event occurs when an element (or any elements inside it) gets focus.
The focusin() method attaches a function to run when a focus event occurs on the element, or any elements inside it.
Unlike the focus() method, the focusin() method also triggers if any child elements get focus.
Parameter | Description |
---|---|
function | Required. Specifies the function to run when the focusin event occurs. |