Codice PHP:
function Points($user_name)
{
//query to calculate the points the user had earned
$query_points "SELECT COUNT(refer_username) FROM referral WHERE refer_username = '$user_name'";
$execute_points mysql_query($query_points);
$result_points mysql_fetch_row($execute_points);
$points $result_points[0];
return 
$points;
};