Reputation: 25348
So right now I'm doing this:
$(".radio_visible").hide().removeClass("radio_visible");
But what I'd like to be able to do is remove all of the radio_visible
classes if it's within a specific ID. Sort of like this:
$(".radio_visible").hide().removeClass("#payment_fields .radio_visible");
So is there another jQuery function I should be looking at to pull that off?
Upvotes: 0
Views: 3454
Reputation: 413717
Maybe
$('#payment_fields *.radio_visible').hide().removeClass('radio_visible');
Upvotes: 0
Reputation: 37547
You could do:
$("#payment_fields .radio_visible").hide().removeClass("radio_visible");
Upvotes: 8