I have the following markup, and I want to make the All
radio button checked.
-
I was beating my head against a wall similar to this and just want to point out that in jQuery 1.3 the syntax used in the accepted answer is the ONLY syntax that will work. The questioner uses the @ syntax for the expression which does not work at all in jQuery. Hopefully this helps the next guy to come across this question via Google =p
To be clear, you have to use
jQuery('input[name=field1][val=checked]')
and not
jQuery('input[@name=field1][@val=checked]')