I'm sure this is painfully simple but I just can seem to find it.
I need to get a selection of textboxes from their value. I don't need the value, I need the elements. I want something like:
$(".ProductCode [value:'hideme']").hide(); I end up with
unrecognized expression: [value:'hideme'] btw,
$(".ProductCode").each(function() { if ($(this).val() == 'hideme') $(this).hide(); }); Is working but it doesn't seem very clean.
each(). When you select elements, you'll preformhide()on all the selected elements. I've edited my answer to include a jsFiddle example that hides 2 text boxes at once.