Look at event delegation using live . From the docs:
"" , ( ). , "li" - click ( , ).
:
$('#myTable td').live("click", function() {
alert('hello!');
});
(), , . live :
(, ) - .
, , :
function bindStuffToTable()
{
$('#myTable td').click(function() {
alert('Hello!');
});
}
$('#myTable').load('/some/link', bindStuffToTable);
, :
$('#someButton').click(function() {
$('#someDiv').load('foo.php', bindStuffToTable);
});