This recipe demonstrates the use of the .trigger()
method to invoke events programmatically. The constructs used in this example are as follows:
Construct |
Type |
Description |
---|---|---|
|
jQuery selector |
This matches all elements with the specified CSS class. |
|
jQuery selector |
This selects all elements with the specified HTML tag. |
|
jQuery object |
This refers to the current jQuery object. |
|
jQuery method |
This returns a string with the required attribute value of the first matched element. It can also be used to set the attribute to the required value. |
|
jQuery selector |
This selects an element with the specified attribute equal to the |
|
jQuery event |
This is fired when you click on an element. It corresponds to the JavaScript |
|
jQuery event |
This is fired when you double-click on an element. It corresponds to the... |