點擊查看后,獲取所在行的內容,不包含操作列的內容`$(".a_see").on('click',function(){ var arrayContent = []; if($("table tr").length>1){
$("table tr").find("td").each(function(){
arrayContent.push($(this).not(".operate").text());
//arrayContent = arrayContent.slice(0,6);
})
}
console.log(arrayContent);
});`表格如下:這是我打印的結果,我點擊查看,所有的表格內容都獲取了,但我只需要當前行的數據
jQuery獲取table中點擊位置所在行的td?
婷婷同學_
2018-08-09 11:10:01