class not working on jQuery prepend
<p>I am prepending a list item <code>&lt;li&gt;</code> to my <code>&lt;ul&gt;</code> in my jQuery code and in the prepended <code>&lt;li&gt;</code> I have a text link that calls fancybox.</p>

<p>Any clicked item with the class 'fb' attached to it will call and open fancybox only the newly appended list item with text link will not open fancy box.</p>

<p>So here is what I have in the prepend </p>

<pre><code>&lt;a class='fb' href='viewtopic?id="+nextlistid+"'&gt;"+title+"&lt;/a&gt;
</code></pre>

<p>I tried removing the (class='fb') from the link and instead gave it a unique id which i later tried adding <code>$("theuniqueid").addClass("fb");</code> but that didnt seem to do it either.</p>

<p>Here's the fancybox code (which works)</p>

<pre><code>$(".fb").fancybox({
    'padding': 0,
    'autoScale': false,
    'transitionIn': 'none',
    'transitionOut': 'none',
    'overlayColor': '#f7f7f7',
    'overlayOpacity': 0.5
});
</code></pre>

<p>Any ideas on how to get the class to attach to the newly prepended item?</p>

<p>Thanks in advance</p>
