function multiple_registration_form_user_register_form_alter in Multiple Registration 7
Same name and namespace in other branches
- 8.2 multiple_registration.module \multiple_registration_form_user_register_form_alter()
- 8 multiple_registration.module \multiple_registration_form_user_register_form_alter()
- 3.x multiple_registration.module \multiple_registration_form_user_register_form_alter()
Implements hook_form_FORM_ID_alter().
File
- ./
multiple_registration.module, line 450 - Add ability to create several registration pages.
Code
function multiple_registration_form_user_register_form_alter(&$form, &$form_state, $form_id) {
$rid = isset($form_state['reg_rid']) ? $form_state['reg_rid'] : NULL;
if ($rid || strstr(current_path(), MULTIPLE_REGISTRATION_SIGNUP_PATH_PATTERN) && is_numeric(arg(2))) {
$form_state['reg_rid'] = $rid ? $rid : arg(2);
$form['#submit'][] = 'multiple_registration_user_register_form_submit';
drupal_alter('multiple_registration_form', $form, $form_state, $form_state['reg_rid']);
}
}