jQuery: ajax content is loading in wrong div class
<p>I have a jQuery vote script that allows a user to vote on a poll that is displayed on a page. On a particular page there are many polls being displayed (via forms) and the jQuery grabs the values of the inputs in a particular form and send the data over to a query.php page.</p>

<p>This is what a sample poll page looks like: </p>

<pre><code>QUESTION 1:&lt;br /&gt;
&lt;div class="poll_area"&gt;
    &lt;div id="poll"&gt;    
        &lt;form method="POST" action="" class="poll_query"&gt;
            &lt;input type="hidden" value="favorites" name="page" /&gt;
            &lt;input type="hidden" value="user1" name="to" /&gt;
            &lt;input type="hidden" name="pid" value="1"/&gt;                            
            &lt;input name="" type="radio" value="yes" /&gt; Yes&lt;br /&gt;
            &lt;input name="" type="radio" value="no" /&gt; No&lt;br /&gt;                        
        &lt;/form&gt;    
    &lt;/div&gt;
    &lt;div class="result"&gt; &lt;/div&gt;
&lt;/div&gt;

QUESTION 2:&lt;br /&gt;
&lt;div class="poll_area"&gt;
    &lt;div id="poll"&gt;    
        &lt;form method="POST" action="" class="poll_query"&gt;
            &lt;input type="hidden" value="favorites" name="page" /&gt;
            &lt;input type="hidden" value="user2" name="to" /&gt;
            &lt;input type="hidden" name="pid" value="2"/&gt;                            
            &lt;input name="" type="radio" value="yes" /&gt; Yes&lt;br /&gt;
            &lt;input name="" type="radio" value="no" /&gt; No&lt;br /&gt;                        
        &lt;/form&gt;    
    &lt;/div&gt;
    &lt;div class="result"&gt; &lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>And this is the jQuery Script I'm running:</p>

<pre><code>var ajax_load = "&lt;img src='images/ajax-loader.gif' alt='loading...' /&gt;";
$("form.poll_query &gt; input[type='radio']").click(function(e) {
    e.preventDefault();
    var form= $(this).closest("form");
    var pid = $("input[name='pid']", form).val();
    var ans = $(this).val();
    var page = $("input[name='page']", form).val();
    var to = $("input[name='to']", form).val();

    $(this).closest("#poll").html(ajax_load);
    $.post(
        "query.php?module=vote",  
        {answer: ans, pid: pid, to: to, page: page},
        function(responseText){  
            $("#poll").hide(0,function() {
                $(".result").html(responseText).fadeIn(1500);
            }); 
        },  
        "html"
    );
});
</code></pre>

<p>When voting in the first poll everything renders correctly. The 'responseText' that is returned is displayed in the page where it is supposed to. But for every subsequent poll on the page the 'ajax_load' loads correctly where it is supposed to but the 'responseText' is loaded in the .result class of the FIRST poll.</p>

<p>This is what the page initially looks like:</p>

<pre><code>Question 1? 
o YES 
o NO

Question 2?
o YES 
o NO
</code></pre>

<p>if a particular user votes on question 2 this is what the page should look like:</p>

<pre><code>Question 1? 
o YES 
o NO

Question 2 
o YES : XXXXXXXXX 60%
o NO  :  XXXXXX 40%
</code></pre>

<p>Instead this is what actually happens (even though the user voted on question 2):</p>

<pre><code>Question 1? 
o YES : XXXXXXXXX 60%
o NO  : XXXXXX 40%

Question 2 
o YES 
o NO
</code></pre>

<p>But if the user votes on question 1 the results is loaded properly:</p>

<pre><code>Question 1? 
o YES : XXXXXXXXX 60%
o NO  : XXXXXX 40%

Question 2 
o YES 
o NO
</code></pre>

<p>I've tried changing <code>$(".result").html(responseText).fadeIn(1500);</code> to <code>$(this).closest(".result").html(responseText).fadeIn(1500);</code></p>

<p>But still no luck. </p>
