title: jquery adding data to a div dynamically
body: <pre><code>&lt;div class="sample"&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I would like to add data to the sample div on click.
  I am able to get the data to this function. verified with alert
  but it is not appending to the sample div.</p>
  
  <pre><code>$("#editsubmit").click(function(){
  
                    var val = $('[name=name111]').val();
                      var newHTML = '&lt;input type="checkbox" name="'+val+'&lt;br&gt;';
                      $("#sample").append( newHTML );
  
             });  
  </code></pre>