$("div tbody tr").click(function() {      
   var rows = $(this).prevAll().length + 1;//行号
   alert(rows );
  });

 


//获取表的总行数 tr

$("#tableid").find("tr").length ;

//获取所在行的行号

$(this).parent().prevAll().length + 1;//行号

//获取所在列的列号

$(this).prevAll().length + 1;//列
---------------------
作者:xhx夏
来源:CSDN
原文:https://blog.csdn.net/u014328353/article/details/78241887?utm_source=copy
版权声明:本文为博主原创文章,转载请附上博文链接!

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-29
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-06-12
  • 2021-10-19
  • 2021-11-14
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案