title: Monitoring when a radio button is unchecked
body: <p>I have an application that shows one div when a certain radio button is selected and then hides that div when the radio button is unselected.  The problem is that the change event attached to the radio button only gets called when the radio button is checked, not when another one is checked (unchecking the previous one).  My current code is as follows:</p>
  
  <pre><code>&lt;form name="newreport" action="#buildurl('report.filters')#" method="post"&gt;
      &lt;dl class="oneColumn"&gt;
          &lt;dt class="first"&gt;&lt;label for="txt_name"&gt;Name&lt;/label&gt;&lt;/dt&gt;
          &lt;dd&gt;&lt;input type="text" name="name" id="txt_name" class="text" /&gt;&lt;/dd&gt;
          &lt;dt&gt;&lt;strong&gt;Type&lt;/strong&gt;&lt;/dt&gt;
          &lt;dt&gt;&lt;input type="radio" name="type" id="rdo_list" value="list" checked="checked" /&gt;&lt;label for="rdo_type" style="display:inline;"&gt;List&lt;/label&gt;&lt;/dt&gt;
          &lt;dd&gt;List a group of records&lt;/dd&gt;
          &lt;dt&gt;&lt;input type="radio" name="type" id="rdo_fields" value="fields" /&gt;&lt;label for="rdo_fields" style="display:inline;"&gt;Field Breakdown&lt;/label&gt;&lt;/dt&gt;
          &lt;dd&gt;Breaks down distinct field values for comparison&lt;/dd&gt;
          &lt;dt&gt;&lt;input type="radio" name="type" id="rdo_history" value="history" /&gt;&lt;label for="rdo_history" style="display:inline;"&gt;Historical Comparison&lt;/label&gt;&lt;/dt&gt;
          &lt;dd&gt;Provides record changes over a group of years for growth comparisons&lt;/dd&gt;
          &lt;dt&gt;&lt;input type="radio" name="type" id="rdo_breakdown" value="breakdown" /&gt;&lt;label for="rdo_breakdown" style="display:inline;"&gt;Student Breakdown&lt;/label&gt;&lt;/dt&gt;
          &lt;dd&gt;Breaks down students by school, district or grade&lt;/dd&gt;
          &lt;div class="reportyear"&gt;
              &lt;dt&gt;&lt;label for="txt_year"&gt;Year to Report&lt;/label&gt;&lt;/dt&gt;
              &lt;dd&gt;&lt;input type="text" name="year" id="txt_year" class="text" value="#year(Rc.yearstart)#" /&gt;&lt;/dd&gt;
          &lt;/div&gt;
          &lt;div class="date-spans" style="display:none;"&gt;
              &lt;dt&gt;&lt;label for="txt_yearstart"&gt;Year Start&lt;/label&gt;&lt;/dt&gt;
              &lt;dd&gt;&lt;input type="text" name="yearstart" id="txt_yearstart" class="text" value="#evaluate(year(Rc.yearstart)-5)#" /&gt;&lt;/dd&gt;
              &lt;dt&gt;&lt;label for="txt_yearend"&gt;Year End&lt;/label&gt;&lt;/dt&gt;
              &lt;dd&gt;&lt;input type="text" name="yearend" id="txt_yearend" class="text" value="#year(Rc.yearstart)#" /&gt;&lt;/dd&gt;
          &lt;/div&gt;
      &lt;/dl&gt;
  &lt;/form&gt;
  
  
  &lt;script type="text/javascript"&gt;
      $(function(){
          $('##rdo_history').change(function(e){
              var isChecked = $(this).attr(checked);
              var $datespan = $('form .date-spans');
              var $year = $('form .reportyear');
  
              if(isChecked){
                  $year.css({display:'none'});
                  $datespan.fadeIn('fast');
              }else{
                  $datespan.css({display:'none'});
                  $year.fadeIn('fast');
              }
          });
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>It seems like a pretty simple script, but the event only gets called on the check event, not on the uncheck event.  Can anyone tell me why?</p>