How to use JQuery Event result Property

This article describe about jQuery Event result Property.
  • 2323

jQuery Event result Property

The last value of mouse pointer returned by an event handler function and contain by the result property, that was triggered by the any specified event.

Syntax

event.result

 

Parameter Description
event Required. It defined event that get last returned value, and event parameter comes from event binding method

Example

<!DOCTYPE html>

<html>

<head>

<script type="text/javascript" src="jquery.js"></script>

<script type="text/javascript">

    $(document).ready(function () {

        $("button").click(function (e) {

            return ("At the time of last click, the mouse position was: X" + e.pageX + ", Y" + e.pageY);

        });

        $("button").click(function (e) {

            $("p").html(e.result);

        });

    });

</script>

</head>

<body>

<p>This is my first paragraph</p>

<button>Click me</button>

</body>

</html>

 

Output


result property pic21.jpg


Note: after click on the button output become


result property pic22.jpg

You may also want to read these related articles Click here

Ask Your Question 

Got a programming related question? You may want to post your question here

Programming Answers here

Categories

More Articles

© 2020 DotNetHeaven. All rights reserved.