Good,
I created this script to check the DB, add all the records with that ID and then give an alert with the total sum.
But ... it's not giving, just show 1 record.
$exp_selector = "SELECT reward_qty FROM public_rewards WHERE client_id = '".$_SESSION['u_id']."'";
$exp_query = $con->query($exp_selector);
$reward_exp = rand(10,25);
while($exp_detail = $exp_query->fetch_array()) {
$percentages = $exp_detail['reward_qty'];
$sum_value += $percentages;
echo "<script>alert('$sum_value');</script>";
}
Why is not adding all this client_id ????