updated json.php to reverse email order