type
UK[taɪp] 美[taɪp]
n.Type; type; (printed or typed) text; type of...
vt.& vi. Typing
vt. [Medicine] determination (blood type); classifying... by type; becoming a typical example of...; [printing] casting (type, etc.)
jquery type attribute syntax
Function: type attribute describes which event type is triggered.
Syntax: event.typ
Parameters:
Parameters | Description |
event | Required. Specifies the events to be checked. The event parameter comes from the event binding function. |
jquery type attribute example
<html> <head> <script type="text/javascript" src="http://apps.bdimg.com/libs/jquery/2.1.1/jquery.min.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("p").bind('click dblclick mouseover mouseout',function(event){ $("div").html("事件:" + event.type); }); }); </script> </head> <body> <p>该段落定义了 click、double-click、mouseover 以及 mouseout 事件。 如果您触发了其中的一个事件,下面的 div 中会显示出事件的类型。</p> <div></div> </body> </html>
Click the "Run instance" button to view the online instance