title: Why doesn't a jQuery change function work after loading html with AJAX?
body: <p>I load a form and dynamically populate a select via AJAX from a PHP file. Before implementing the dynamic AJAX populated select, my change function works (it just shows another input when a user selects 'other'). Now the change function does not work.</p>
  
  <p>I know the ready function is firing because the jStepper functions run. I have tried this with the change function in and outside the ready function. I have a feeling the change function loads before the AJAX get is finished, but does that really matter?</p>
  
  <pre><code>var types = "&lt;select name='ve_categoryNo' id='ve_categoryNo'&gt;";
  var d = new Date();
  $.get('scripts/vehicle_category_feed.php?date=' + d.getTime(), function ($type)
  {
      $($type).find('type').each(function ()
      {
          types += "&lt;option value='" + $(this).attr("categoryno") + "'&gt;" + $(this).attr("category") + "&lt;/option&gt;";
      });
      types += "&lt;option value='other'&gt;Other(Specify)&lt;/option&gt;&lt;/select&gt;";
      $('#ve_categoryNo_td').html(types);
  });
  $(document).ready(function ()
  {
      $('input[type=text]').click(function ()
      {
          $(this).select();
      });
      $('#vehicle_entry').ajaxForm(function ()
      {
          showMessage('vehicle_information_added');
      });
      $('#ve_ariNo').jStepper({minValue: 1, maxValue: 99999999});
      $('#ve_fleetNo').jStepper({minValue: 1, maxValue: 999999999});
      $('#ve_vehicleYear').jStepper();
      $('#ve_purchasePrice').jStepper({minValue: 0});
      $('#ve_categoryNo').change(function ()
      {
          if ((this.value) == "other")
          {
              $('#otherCategory').show();
              $('#otherCategory input[type=text]').focus();
          } else
          {
              $('#otherCategory').hide();
          }
      });
  });
  </code></pre>