aaaaa
以上是一个显示数据用的 tbody区域
我点击class为test的button时
怎么获得前面那个有值的td的结点的事件呢?
比如这个结点
aaa
[code="java"]
...
$(document).ready(function(){ $(".test").click(function(){ $("tr").each(function(){ if($(this).text()!=""){ var textVal = $(this).text();//这里就是你要的值 } }); }); });
[/code]
不太明白问题