title: jquery: toggle a fieldset based upon a specific checked checkbox in an array of multiple checkboxes
body: <p>Using jquery, given <strong>multiple</strong> checkboxes, how please would we toggle a fieldset on/off if a <strong>particular</strong> checkbox is checked/ unchecked? (more than one checkbox may be chosen as this is multiple)</p>
  
  <p>I've tried using ':checked' and 'jQuery.inArray' together with toggle() but no luck yet. 
  Example HTML without the script:</p>
  
  <pre><code>&lt;form&gt;
  
   Which food group do you like?
   &lt;input type="checkbox" name="nutrition[]" value="Fruit"&gt;
   &lt;input type="checkbox" name="nutrition[]" value="Vegetables"&gt;
   &lt;input type="checkbox" name="nutrition[]" value="Sweets"&gt;
  
  &lt;!-- show this input (toggle on/off) only if 'Fruit' is one of the checked boxes--&gt;
  &lt;fieldset id="someid" style="display:none;&gt;
   You chose Fruit! Name one fruit: &lt;input type="text" name= "afruit" /&gt;
  &lt;/fieldset&gt;
  
  &lt;/form&gt;
  </code></pre>
  
  <p> ?  </p>
  
  <p>here is the complete html + script based on Jason P's answer, using id as selector:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;script src="http://code.jquery.com/jquery-1.10.2.js"&gt;&lt;/script&gt;
  &lt;script&gt;
  window.onload = function() {
  $('#fruitid').change(function(e) {
      $('#someid').toggle(this.checked);
  });
  };
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;form&gt;
   Which food group do you like?
   &lt;input type="checkbox" name="nutrition[]" value="Fruit" id="fruitid"&gt;
   &lt;input type="checkbox" name="nutrition[]" value="Vegetables"&gt;
   &lt;input type="checkbox" name="nutrition[]" value="Sweets"&gt;
  
  &lt;!-- show this input (toggle on/off) only if 'Fruit' is one of the checked boxes--&gt;
  &lt;fieldset id="someid" style="display:none;"&gt;
   You chose Fruit! Name one fruit: &lt;input type="text" name= "afruit" /&gt;
  &lt;/fieldset&gt;
  
  &lt;/form&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>