You are here

function pcp_form_user_profile_form_alter in Profile Complete Percent 6.2

Implementation of hook_form_FORM_ID_alter().

File

./pcp.module, line 104
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_profile_form_alter(&$form, $form_state) {
  if (isset($_GET['fieldname']) && $_GET['fieldname'] != '') {
    $fieldname = 'edit-' . preg_replace("/_/", "-", $_GET['fieldname']);
    drupal_add_js("\n      \$('#" . $fieldname . "').css({\n        'border' : '2px solid red'\n        });\n    ", 'inline', 'footer');
  }
}