代码之家  ›  专栏  ›  技术社区  ›  Kieran Senior

TD不包含文本的地方

  •  4
  • Kieran Senior  · 技术社区  · 16 年前

    $("table tr td:contains('" + $("#SupplierID :selected").text() + "')").parent().hide();
    

    3 回复  |  直到 16 年前
        1
  •  14
  •   Greg    16 年前

    $("table tr td:nth-child(...):not(:contains(...))")
    
        2
  •  1
  •   meder omuraliev    16 年前
    :not(:contains("text"))
    

        3
  •  0
  •   Vladimir Vagaytsev    9 年前

    not()

    • $('td:nth-child(1)').not($('td:contains("DoNotHide")')).parents('tr').hide()

    • $('tr').not($('td:contains("DoNotHide")').parents('tr')).hide();