jQuery event.target Property Last Updated : 07 Jul, 2023 Suggest changes Share Like Article Like Report The jQuery event.target is an inbuilt property that, is used to find which DOM element will start the event. Syntax: event.targetParameter: It does not accept any parameter because it is a property, not a function. Example 1: This example shows the working of event.target Property. HTML <!DOCTYPE html> <html> <head> <style> span, strong, p { padding: 8px; display: block; border: 2px solid green; width: 50%; margin: 10px; } #output { margin: 10px; padding: 10px; width: 100px; border: 2px solid green; display: block; } </style> <script src= "https://code.jquery.com/jquery-1.10.2.js"> </script> </head> <body> <div> <p> <strong><span>click Here !</span></strong> </p> </div> <!-- output will show inside this block --> <div id="output"></div> <!-- jQuery code to show working of this property --> <script> $("body").click(function (event) { $("#output").html("clicked: " + event.target.nodeName); }); </script> </body> </html> Output: Example 2: In this example, a pop-up will come when any DOM element is clicked. HTML <!DOCTYPE html> <html> <head> <style> span, strong, p { padding: 8px; display: block; border: 2px solid green; width: 50%; margin: 10px; } </style> <script src= "https://code.jquery.com/jquery-1.10.2.js"> </script> </head> <body> <center> <div> <p> <strong><span>click Here !</span></strong> </p> </div> <!-- jQuery code to show working of this property --> <script> $("body").click(function (event) { $("").html("clicked: " + event.target.nodeName); alert(event.target.nodeName + " is clicked"); }); </script> </center> </body> </html> Output: K kundankumarjha Follow Article Tags : Web Technologies JQuery jQuery-Propertie Explore jQuery Tutorial 8 min read Getting Started with jQuery 4 min read jQuery Introduction 7 min read jQuery Syntax 2 min read jQuery CDN 4 min read jQuery SelectorsJQuery Selectors 5 min read jQuery * Selector 1 min read jQuery #id Selector 1 min read jQuery .class Selector 1 min read jQuery EventsjQuery Events 4 min read jQuery bind() Method 2 min read jQuery blur() Method 1 min read jQuery change() Method 2 min read jQuery EffectsjQuery animate() Method 2 min read jQuery clearQueue() Method 2 min read jQuery delay() Method 2 min read jQuery HTML/CSSjQuery addClass() Method 2 min read jQuery after() Method 1 min read jQuery append() Method 2 min read jQuery TraversingjQuery | Traversing 4 min read jQuery add() method 1 min read jQuery addBack() Method 2 min read My Profile ${profileImgHtml} My Profile Edit Profile My Courses Join Community Transactions Logout Like