Events on ajax-got HTML form

Events on ajax-got HTML form

So, this is JavaScript
  1. $(document).ready(function(){
  2.     $('#lgn_form').submit(function() {
  3.         ajax($(this).serialize(),'toolSection','lgn_form');
  4.         return false;
  5.     });   
  6. });
  7. function ajax(data,section,source) {
  8.     $.ajax({
  9.         type: "POST",
  10.         url: "core/ajax.php",
  11.         data: data+'&section='+section+'&source='+source,
  12.         success:    function(html){
  13.             id = "#"+section;
  14.             $(id).html(html);
  15.         }
  16.     });
  17. }
I use this, to manage user login-session, into small container inside my page.
I wont post whole PHP here, but the thing is, when I send data to server and it receives an answer, I clear a contents of container (in which, login form resided), and insert my answer. Problem comes, when there is situataion, when login fails, it gives in response a new login form, with same ID (#lgn_form), but JavaScript does not "see" that ID, so it does not respond, on submit button.
It there any solution to make JS respond to ajax generated content ID's?