I sometimes see that there is something like this:
<input name="star2" type="radio" class="star 1"/>
<input name="star2" type="radio" class="star 2"/>
is it possible in jQuery to let one class to handle these two class? Because basically they have the same parent class, which is star? If it is possible, how can I do that? Using regular expression?
Yes, you can select both of them with
$('.star'). What you may have been trying to refer to is starts with attribute selector.Also, I doubt that
1is a valid class name.