[jQuery] Radio button checked status
Banging my head against a wall here. I have this:
<h3><span class="num">1</span>Date Range</h3>
<input type="radio" class="period" name="period" value="daily">
Daily
<input type="radio" class="period" name="period" value="weekly">
Weekly
<input type="radio" class="period" name="period" value="monthly">
Monthly
and I'm trying to get checked status with this:
var period = $('input.period:checked').val();
But, of course, no joy. Do *I* need to set the checked status of the
radio button in order to use the :checked method, or doesn't the
browser handle this on it's own? I thought browsers changed the
"checked" attribute on their own. I'm totally stumped and cranky over
here.
Thanks!
-Nick