I have right now this code:
<ul><li class="listitem">text<li></ul>
jQuery:
$('.listitem').click(function() {
$("#elname").text($(this).text());
$('#slists').css('visibility','hidden')
$('#elname').css('visibility','visible')
$('#elname').css('display','inline-block')
});
This is supposed to hide a div and it does, but when I append items to the ul (with the class listitem) nothing happens with the appended item, the class it gets is correct, the title, and the value too.
Can this have something to do with the code above being in the document ready function to do?