Andreu | abbcb7e | 2019-09-21 18:22:14 +0200 | [diff] [blame] | 1 | <?php |
2 | require '../php/utils.php'; | ||||
Andreu | 09b8b05 | 2019-09-21 21:47:20 +0200 | [diff] [blame^] | 3 | $user = get_users($_POST['id']); |
Andreu | abbcb7e | 2019-09-21 18:22:14 +0200 | [diff] [blame] | 4 | |
5 | echo '{ '; | ||||
6 | $first = true; | ||||
7 | foreach ($user as $prop => $value) { | ||||
8 | if (!$first) echo ', '; | ||||
9 | else $first = false; | ||||
10 | if ($prop == "nomcomplet") echo '"'.$prop.'": "'.$value.'"'; | ||||
11 | else echo '"'.$prop.'": '.$value; | ||||
12 | } | ||||
13 | echo ' }'; | ||||
14 | ?> |