首页javascriptmousejQuery Event - 如何将右键单击事件附加到div...

jQuery Event - 如何将右键单击事件附加到div...

我们想知道如何将右键单击事件附加到div。...

<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
  src='http://code.jquery.com/jquery-1.10.1.js'></script>
<script type='text/javascript'>
$(window).load(function(){
    $( "#outer" ).mouseenter(function() {
      $( ".csTip" ).append( "<div>Handler for .mouseenter() called.</div>" );
    });
});
</script>
</head>
<body>
  <table>
    <th id='outer'>Agreed Bid <span class='csTip'>Hover me</span>
    </th>
  </table>
</body>
</html>