I have html table like this:
<div id="recommendation">
<table id="category_selected">
<tr>
<td>1</td>
</tr>
</table>
</div>
and jquery like this:
$(function()
{
$("#recommendation tr").mouseenter(function()
{
alert("Yes");
}
}
and everything works fine. But when I change html of recommendation with this:
$.post("path/script.php", {dataIn: dataInEncoded}, function(data, status)
{
if(status == 'success')
{
$("#recommendation").html(data);
/*(data exactly the same as default html)
<table id="category_selected">
<tr>
<td>1</td>
</tr>
</table>
*/
}
}
Jquery mouseenter suddenly doesn't work (trigger).