jQuery click() event; how to prevent this event on right mouse btn click?
- by Kirzilla
Hello,
<img src="" width="200" height="200" id="test_img" />
<script>
$("#test_img").click(function() {
alert("Hello");
});
</script>
But it doesn't matter what mouse button I'm pressing - right or left. I see absolutely the same result. I want alert to be shown only on left mouse button click.
Thank you and sorry; I'm…