Hey there, I've got a drop down menu that's being shown using UL and LI tags. This is generated by a PHP script that echos out:
'<li id='. $value .'>'.$value.'</li>'
The JQuery function below works perfectly fine for the LI elements created this way. The list gets updated dynamically by another AJAX PHP script. The AJAX echoes out the EXACT same thing (just copied and pasted). The display looks good, but strangely, the JQuery function/Event Listener no longer applies to the LI elements.
Any ideas why this might be happening? Thanks in advance!
$('li').click(function() {
//do something here
alert('it works');
}