jQuery click not working on appended dom
<p>I appended some div like this :</p>

<pre><code>var to = "Some content"
$("#key").append("&lt;div class=\"cont\"&gt;"+to+"  &lt;span ded="+ lastid +" class=\"\contspan\"&gt;X&lt;/span&gt;&lt;/div&gt;  ");
</code></pre>

<p>Then i tried to bind a click on event on the div with class <code>cont</code> by doing this :</p>

<pre><code>$('.cont').delegate('div', 'click', function() {
    $("#logger").html("click")
});
</code></pre>

<p>But this doesnt works ?
Where have i been going wrong ?</p>

<p><strong>EDIT</strong>:
I tried to place a bacground color to the class <code>cont</code> And the color is there to show that class id added fine</p>
