function pcp_form_user_admin_settings_alter in Profile Complete Percent 6.2
Same name and namespace in other branches
- 7 pcp.module \pcp_form_user_admin_settings_alter()
Implementation of hook_form_FORM_ID_alter().
File
- ./
pcp.module, line 74 - Allows users with valid permissions to tag profile fields created from the profile module as required fields for a users profile to be considered complete.
Code
function pcp_form_user_admin_settings_alter(&$form, $form_state) {
if (user_access('administer pcp')) {
$form['pictures']['settings']['pcp_enable_user_picture'] = array(
'#title' => 'Make required for PCP module',
'#type' => 'checkbox',
'#default_value' => variable_get('pcp_enable_user_picture', 0),
'#description' => t('Checking this box will tag this field as a required field for completion of the users profile.'),
);
$form['#submit'][] = 'pcp_user_admin_settings_submit';
}
}