function og_add_users in Organic groups 6
Same name and namespace in other branches
- 5.8 og.module \og_add_users()
- 5 og.module \og_add_users()
- 5.2 og.module \og_add_users()
- 5.3 og.module \og_add_users()
- 5.7 og.module \og_add_users()
- 6.2 og.pages.inc \og_add_users()
File
- ./
og.module, line 1159
Code
function og_add_users($form_state, $group_node) {
$form['og_names'] = array(
'#type' => 'textarea',
'#title' => t('List of users'),
'#rows' => 5,
'#cols' => 70,
// No autocomplete b/c user_autocomplete can't handle commas like taxonomy. pls improve core.
// '#autocomplete_path' => 'user/autocomplete',
'#description' => t('Add one or more usernames in order to associate users with this group. Multiple usernames should be separated by a comma.'),
'#element_validate' => array(
'og_add_users_og_names_validate',
),
);
$form['op'] = array(
'#type' => 'submit',
'#value' => t('Add users'),
);
$form['gid'] = array(
'#type' => 'value',
'#value' => $group_node->nid,
);
return $form;
}