title: jquery scroll to an element that has been created on the fly via ajax
body: <p>I'm current using the solution provided in this answer <a href="https://stackoverflow.com/questions/6677035/jquery-scroll-to-element">jQuery scroll to element</a> however, the problem I have is that the element I want to scroll to has been inserted into the dom via ajax so the function does not actually work. I'm assuming that jquery does not know the element exists yet as the page has not actually been reloaded.</p>
  
  <p>I've used things like jquery .delegate in the past for click/onchange events but, I'm not sure if/how I can use something similar so that jquery can find the newly created element.</p>
  
  <p>Any ideas on how I can do this? The code I'm currently using at the moment to do the scrolling is:</p>
  
  <p>$('html, body').animate({ scrollTop: $("#comment_row_"+comment_id).offset().top }, 2000);</p>