I want to add a real name field beside the default username when I creat a new user in
admin/people/create. How can I do this?
I have checked the RealName module but is not doing what I need.
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.Sign up to join this community
Simply add a textfield (or two, if you want first/lastname) to your users at admin/config/people/accounts/fields. That will allow them to enter their realname and it will be displayed on the user profile page.
And if you want to display that name in various places (like node author), that's exactly what Realname module is for. It allows to configure the displayed name based on tokens (which can either be profile fields or user fields).
The best module for this is https://drupal.org/project/name, I would guess. It manages given, last and middle names and all sorts of suffixes and prefixes like "Dr.", "Jr." and so on. It even has settings for the order of first and last name, so an asian user could choose to display his last name first and a european user his first name.
Profile2 is recommended over the core profile fields, because as the module page says:
Designed to be the successor of the core profile module, which is deprecated for Drupal 7. In contrast to the deprecated module this module provides a new, fieldable 'profile' entity - leverage the power of fields!
The Real name module, once you understand it, is simple, but there are no instructions at all (!?).
Here is my version of short instructions to help folks out there: For Drupal 7 only.
The name shown for accounts will automatically be replaced by the chosen token or profile field.