javascript - Hide parentNode based on grandChild innerHTML -


i need hide entire row based on childnodes innerhtml. in form have status dropdown menu hiding on it's own doesn't ride of row. how set display of none?

enter image description here

using like:

$("nobr").filter(function () {     return $.trim(this.childnodes[0].nodevalue) === "status"; }).closest("tr").hide(); 

this finds all <nobr> elements on page, gets first child node (which in example, text node whitespace , text "status"), , checks text "status".

this need updated if order of elements in <nobr> isn't example shows, or differs across rows, or else, because specific search.

of course, can narrow <nobr> elements targeted @ first. example, if html wanted target within table, first find table , @ <nobr> elements within:

$("#table_id").find("nobr").filter(func... 

Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -