0
下面的代碼是通過全部div
內的input
和select
元件循環和檢查該值是空的,然後隱藏它,它可以正常使用:循環通過輸入和選擇元件和隱藏先前TD
$("#customfields_1 :input").filter(function() {
return $.trim(this.value).length === 0;
}).hide();
但現在我真正想要的是隱藏以前td
,是這樣的:使用前
$("#customfields_1 :input").filter(function() {
return $.trim(this.value).length === 0;
}).prev('td').hide();
這絕對是我所需要的,TNK你 – user2077308 2013-02-16 01:42:03
@ user2077308 - 那麼你應該接受這個答案! – adeneo 2013-02-16 01:54:20