Multiple Ajax loading indicators on 1 page
<p>I have a page with 2 separate forms that can be submitted via Ajax (jQuery). For each of these forms I'd like to show a loading indicator to the user. I have found a nice piece of code that can easily show these icons, but it only works when there's 1 form.</p>

<pre><code>$('.ajaxloader').hide().ajaxStart(function () { 
    $(this).show(); 
}).ajaxStop(function () {
    $(this).hide(); 
});
</code></pre>

<p>ajaxloader is a class which shows the loading image as a CSS background image. To use it, I just need to add something like: <code>&lt;span class="ajaxLoader"&gt;Busy ...&lt;/span&gt;</code></p>

<p>When I test this with my page (that has 2 forms), and I submit one of the two, then both loading indicators appear (which is quite obvious). Now my question is, how can I show the indicator that needs to be shown? I was thinking about giving the span-tag an id attribute, but then I don't know how to proceed. I want this to be as generic as possible, so I don't have to hardcode and duplicate code a lot.</p>

<p>Thanks!</p>
