title: Getting jQuery to recognise .change() in IE
body: <p>I'm using jQuery to hide and show elements when a radio button group is altered/clicked. It works fine in browsers like Firefox, but in IE 6 and 7, the action only occurs when the user then clicks somewhere else on the page.</p>
  
  <p>To elaborate, when you load the page, everything looks fine. In Firefox, if you click a radio button, one table row is hidden and the other one is shown immediately. However, in IE 6 and 7, you click the radio button and nothing will happen until you click somewhere on the page. Only then does IE redraw the page, hiding and showing the relevant elements.</p>
  
  <p>Here's the jQuery I'm using:</p>
  
  <pre><code>$(document).ready(function () {
    $(".hiddenOnLoad").hide();
  
    $("#viewByOrg").change(function () {
      $(".visibleOnLoad").show();
      $(".hiddenOnLoad").hide();
    });
  
    $("#viewByProduct").change(function () {
      $(".visibleOnLoad").hide();
      $(".hiddenOnLoad").show();
    });
  });
  </code></pre>
  
  <p>Here's the part of the XHTML that it affects. The whole page validates as XHTML 1.0 Strict.</p>
  
  <pre><code>&lt;tr&gt;
    &lt;td&gt;View by:&lt;/td&gt;
    &lt;td&gt;
      &lt;p&gt;
        &lt;input type="radio" name="viewBy" id="viewByOrg" value="organisation"
        checked="checked" /&gt;Organisation&lt;/p&gt;
      &lt;p&gt;
        &lt;input type="radio" name="viewBy" id="viewByProduct" value="product" /&gt;Product&lt;/p&gt;
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr class="visibleOnLoad"&gt;
    &lt;td&gt;Organisation:&lt;/td&gt;
    &lt;td&gt;
      &lt;select name="organisation" id="organisation" multiple="multiple" size="10"&gt;
        &lt;option value="1"&gt;Option 1&lt;/option&gt;
        &lt;option value="2"&gt;Option 2&lt;/option&gt;
      &lt;/select&gt;
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr class="hiddenOnLoad"&gt;
    &lt;td&gt;Product:&lt;/td&gt;
    &lt;td&gt;
      &lt;select name="product" id="product" multiple="multiple" size="10"&gt;
        &lt;option value="1"&gt;Option 1&lt;/option&gt;
        &lt;option value="2"&gt;Option 2&lt;/option&gt;
      &lt;/select&gt;
    &lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>
  
  <p>If anyone has any ideas why this is happening and how to fix it, they would be very much appreciated!</p>