emergencycontact ORDER BY id

This commit is contained in:
james 2011-03-01 17:59:08 +00:00
parent d3801e5a17
commit 3419f06b0b

View File

@ -97,7 +97,7 @@ function user_load($users_id, $accounts_id = false)
if(array_key_exists('participant', $u['roles'])){
$u['emergencycontacts'] = array();
$fields = array('firstname', 'lastname', 'relation', 'phone1', 'phone2', 'phone3', 'phone4', 'email');
$q = mysql_query("SELECT " . implode(',', $fields) . " FROM emergencycontact WHERE users_id = $users_id");
$q = mysql_query("SELECT " . implode(',', $fields) . " FROM emergencycontact WHERE users_id = $users_id ORDER BY id");
while($row = mysql_fetch_assoc($q)){
$u['emergencycontacts'][] = $row;
}