Demo
Code
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script type="text/javascript">
$(document).keyup(function(event) {
if (event.which == 27) {
$('#butt').click();
}
});
$(document).ready(function(){
$("#butt").click(function()
{
alert('Man');
});
a
});
</script>
<button id="butt" >Press Esc</button>
Code
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script type="text/javascript">
$(document).keyup(function(event) {
if (event.which == 27) {
$('#butt').click();
}
});
$(document).ready(function(){
$("#butt").click(function()
{
alert('Man');
});
a
});
</script>
<button id="butt" >Press Esc</button>
Comments
Post a Comment