title: PHP If Variable isset add input with checkbox checked not working
body: <p>I am having a problem with some code...</p>
  
  <p>Here is the code:</p>
  
  <pre><code>&lt;?php
  if (isset($myVar)) {
  echo '&lt;input type="checkbox" name="ck1" id="ck1" checked /&gt;Checked/Not checked';
  }
  ?&gt;
  </code></pre>
  
  <p>I've tried checked, checked="checked" checked="true" ...but for some reason the checkbox doesn't come out checked.</p>