false)); // this html must be synced with the userpicker.js library $code = '
  • '; $code .= "
    $icon
    "; $code .= ""; $code .= "
    " . $user->name . "
    "; $code .= "
    "; $code .= ""; $code .= '
  • '; return $code; } // loop over all values and prepare them so that "in" will work in javascript $values = array(); if (!is_array($vars['value'])) { $vars['value'] = array($vars['value']); } foreach ($vars['value'] as $value) { $values[$value] = TRUE; } // convert the values to a json-encoded list $json_values = json_encode($values); // create an HTML list of users $user_list = ''; foreach ($vars['value'] as $user_id) { $user_list .= user_picker_add_user($user_id); } ?>