title: Manipulating elements after AJAX load()
body: <p>I am trying to manipulate some elements after I load them using .load(). I have everything loading correctly, but I can't seem to target any elements within any of the loaded elements. This seems like something that would be easy, but I just can put my finger on it. </p>
  
  <p>I am using a callback after the elements load, but the DOM seems to not be aware of their existence?</p>
  
  <pre><code>function load_page(){
      $('#page_name').load("/page-name/ .page", null, load_complete());
  }
  
  function load_complete() {
      $('#page_name .book_img').addClass('hello');
  }
  </code></pre>
  
  <p>Ok, this is where I am at now. I have added...</p>
  
  <pre><code>$('#wrapper').ajaxComplete(function() {
      $('#page_name .book_img').addClass('hello');
  }
  </code></pre>
  
  <p>which works. There must be a difference between the .autoComplete and the callback which is packaged with the .load() function. I don't really like this because it is called every time an AJAX event is finished loading, but it does get me a little further down the road.</p>
  
  <p>Anybody have anything better?</p>
  
  <p>[EDIT]</p>
  
  <p>I also tried...</p>
  
  <pre><code>$('#wrapper').ajaxComplete(function() {
      $('#page_name .book_img').addClass('hello');
  }
  </code></pre>
  
  <p>Which is kind of nice since it waits till all AJAX calls are done before calling the function. Maybe this is the way to do it, but it still seems like the .load() function would take care of this?</p>