title: How to make jquery load() in external javascript function?
body: <p>i'm trying to create my own tool in javascript, which will help me load some php functions/files into my div.</p>
  
  <p>Here is my javascript:</p>
  
  <pre><code>$(document).ready(function () {
      $('.btn').click(function() {        
          $('#someid').testit();
          //   $('#someid').load('somefile');  it works
          return false;
      })   
  });
  
  function testit() { 
      $(this).load('somefile');
  }
  </code></pre>
  
  <p>And my html:</p>
  
  <pre><code>&lt;div id="someid"&gt;&lt;/div&gt;
  &lt;form&gt;
      &lt;input type="submit" value="test" class="btn" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>I can't load the resource from external function - why is that?</p>