编程学问
  • 文章
  • 问题
  • 读书
  • 关于
  • 登录
jQuery API 开发手册

返回值:Anythingevent.data

V1.1概述

当前执行的处理器被绑定的时候,包含可选的数据传递给jQuery.fn.bind。

示例

描述:

The description of the example.

jQuery 代码:
$("a").each(function(i) {
    $(this).bind('click', {index:i}, function(e){
       alert('my index is ' + e.data.index);
    });
  });   
相关文章
event.data jqueryevent.isdefaultprevented jqueryevent.isimmediatepropagationstopped jqueryevent.ispropagationstopped jqueryfocusin data fn jqueryfocusout data fn jqueryjquery.data element key value jqueryjquery.get url data callback type jquerymouseover data fn jquerymouseup data fn jqueryon events selector data fn jqueryjquery data key value jquery dblclick data fn jquery error data fn jquery load url data callback jquery mousedown data fn jquery mouseenter data fn jquery unload data fn php libevent 函数 read data from a buffered eventphp swoole event write data to the socket.
关注编程学问公众号
编程学问网 湘ICP备20001732号