title: How to set value of checkbox in codeigniter and show checked state?
body: <p>I have a series of checkboxes in codeigniter and need to show the checked state and value when a form is submitted.</p>
  
  <p>How can I do this?? I have read the documentation of the codeigniter website but cannot see how to set the checked state?</p>
  
  <p>This is my code:</p>
  
  <pre><code>&lt;?php echo form_checkbox('spa', 'y', FALSE, '') ?&gt;
  </code></pre>