php POST summation
<p>i am sending 5 different data across to a php file through POST method. the data is all integers. i want to add up all these integer values to produce a sum. </p>

<pre><code>    $.post(
        "user_submit.php", 
        {score: $('#ques'+qn).find('input[name=vote]:checked').val() }, 
        function(data){
            $("#ques"+qn).hide();
            ++qn;
            $("#ques"+qn).show();
        });
    });
</code></pre>

<p>in the php file:</p>

<pre><code>$score = $_POST['score'];
$total = $total + $score;
echo $total;
</code></pre>

<p>it is not adding up the values. what am i doing wrong?</p>
