function og_massadd_massadd_form in Organic Groups Mass Add 7
Same name and namespace in other branches
- 6 og_massadd.module \og_massadd_massadd_form()
Mass adding users form
1 string reference to 'og_massadd_massadd_form'
- og_massadd_menu in ./
og_massadd.module - Implements hook_menu().
File
- ./
og_massadd.module, line 127 - The og_massadd module file
Code
function og_massadd_massadd_form($form, &$form_state, $group_type, $group_id) {
global $user;
$form['group_type'] = array(
'#type' => 'value',
'#value' => $group_type,
);
$form['group_ids'] = array(
'#type' => 'value',
'#title' => t('Groups to add the user to'),
'#value' => array(
$group_id,
),
'#required' => TRUE,
);
$form['massadd'] = array(
'#type' => 'textarea',
'#title' => t('List of users to add'),
'#description' => t('A list of users to add. The contents can either be lines consiting of FIRSTNAME, LASTNAME, EMAIL or FIRSTNAME, LASTNAME, EMAIL, USERNAME or a list of email addresses (one on each line).'),
'#rows' => 20,
'#default_value' => '',
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Add users'),
);
return $form;
}