<html>
<head>
<script>
function show_coords(event) {
document.getElementById("demo").innerHTML = "X= " + event.clientX + "<br>Y= " + event.clientY;
}
</script>
</head>
<body>
<p onmousedown="show_coords(event)">
Click this paragraph to display the x and y coordinates of the mouse pointer.</p>
<p id="demo"></p>
</body>
<!-- Mirrored from www.w3schools.com/js/tryit.asp?filename=tryjs_dom_event_clientxy by HTTrack Website Copier/3.x [XR&CO'2014], Mon, 27 Jan 2020 02:41:14 GMT -->
</html>