Why is my jquery .load() function not working?
<p>I have a button on my site which, when clicked on, should load html inside a div container. </p>

<p>I'm using the following code for the button:</p>

<pre><code>&lt;div id="nextnr1"&gt;&lt;a href = "#"&gt;Next&amp;gt;&amp;gt;&lt;/a&gt;&lt;/div&gt;
</code></pre>

<p>The following code to execute the loading when someone clicks on the div:</p>

<pre><code>&lt;script type="text/javascript"&gt;
    $(document).ready(function() {
        $("#nextnr1").mousedown(function() {
            $("#Container").load("wrappers.php?currenttab=1&amp;shift=1");
        });
    });​
&lt;/script&gt;
</code></pre>

<p>This is the code for the container where the HTML is loaded into:</p>

<pre><code>&lt;div id="Container"&gt;&lt;/div&gt;
</code></pre>

<p>The problem is that all of the above code is working most of the time. Only once in a while the function <code>.load</code> is not doing his job. This is for similar circumstance because it is about the same page. </p>

<p>I checked that when there is a click the function was called so: <code>$(document).ready</code> and <code>$("#nextnr1").mousedown(function() {..}</code> are doing their job. Only <code>.load</code> is <strong>NOT</strong> doing its job because I checked that there was no HTTP request sent to the server.</p>

<p>If anyone can help me out with this problem I would be very very thankful. </p>

<p><strong>UPDATE 1</strong></p>

<p>I tried the message box (see code below) and it shows that when the load was not executed it also didn't show the message box Load was performed. I also saw that after 2/3 minutes suddenly the message box showed up and it reloaded! However it does work but sometimes there is a huge delay.</p>

<pre><code>$(document).ready(function() {
   $("#renextnr2").click(function() {
      $("#Container").load("wrappers.php?currenttab=2&amp;shift=1", function() {
           alert("Load was performed.");
      });
   });
});
</code></pre>
