Collecting custom user-profile information

Get to know your site’s members better! Prompt your new members to complete one or more required or optional user profile fields when they join your site. Existing members are also prompted for this information when editing their site’s user profile. With custom user profile fields, you can:

  • Define one or more fields to be collected as part of the site registration flow or when editing their site profile.
  • Specify the field name, help text, and display format of the field, such as list, check boxes, text box, and radio buttons.
  • Specify which fields are required or optional. Visitors joining your site will be redirected to the profile form until any required fields are filled in. If you add a required field after a user is created, the next time that user clicks their name to edit their profile, they will be asked to complete the required field in order to continue on to the site.

After you create your fields, you can control who can access and edit these fields.

Adding custom registration fields

  1. Go to Modules and enable the Edit profile module.
  2. Configure the fields you want at Configuration > Account settings.
  3. Click the Manage Fields tab.
  4. To add a custom user profile field, fill out the Add a new field form including the following information:
    • Label - What the user sees.
    • Machine name - An internal name. (Drupal Gardens creates a machine name based on the field's label, but you can edit this value.)
    • Field type - Includes date, text, number, list, file, and image.
    • Widget - Includes check boxes and radio buttons.
  5. Complete the field’s details including help text. For example, “Please tell us your favorite color”.
  6. Configure how you want to collect information for the field:
    • To collect the information when a new user registers on your site, select Display on user registration form.
    • To make this field mandatory for all new users to fill out before they can join the site, select Required field.

  7. Click Save settings.
  8. To add another field, click Manage fields or go to step 2 above.

Now when any user clicks their username on the site, they can click Edit profile to change the value of these custom user profile fields. Also, depending on how you configured your field in step 6, a new user that joins your site will be prompted to fill in your new field(s).