By John Whelan on Friday, 09 May 2014
Posted in General Issues
Replies 9
Likes 0
Views 1K
Votes 0
I need to make the 'Name' field entirely optional for my users as I want them to have the ability to register for my site by providing just a username.

I know that Joomla requires the Name field and that I'll need to be a little creative to work around it. Has anyone done this already? I'd be interested in suggestions on how to do this most efficiently.

Should I just hide the field and fill it with 'joomla_name_goes_here' or something like that?
Hi,

I will be adding a non required mode for fullname, and fullname will fallback to username in the next release.
·
Friday, 09 May 2014 10:53
·
0 Likes
·
0 Votes
·
0 Comments
·
Great!

Ideally the fullname field would have the following characteristics:

1) be non required (and left empty if possible)
2) be possible to hide entirely during user registration
3) could be added later by the user if they so wish (so the field would still appear in their profile, etc.)

Is the above what you already have in mind?
·
Sunday, 11 May 2014 04:12
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks for sharing John. Our idea is that when full name is not required, the field wouldn't appear at all. Perhaps we could make it optional in the sense where if the name field was left blank, the username will be carried over instead
·
Sunday, 11 May 2014 16:21
·
0 Likes
·
0 Votes
·
0 Comments
·
I think that would work. My use case is as follows:

1) I want my users to be able to register with just a username and password. This is for privacy purposes. Many sites do this.
2) In the user's profile, I'd like them to be able to add their Real Name if they choose, so if this was to default to username that would probably work

What is it about the Joomla code that requires the name? Is it a simple setting somewhere? I've looked at administrator/com_users/models/forms/users.xml and see the flag that specifies that the name is required. Is the fix as simple as turning this off?
·
Monday, 12 May 2014 01:16
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello John,

Not just that, many 3rd party apps / plugins / modules etc are already adapted to understand that "Name" is always there. If you do not have it, it might break the flow of the apps / plugins. The only way around this is to "automagically" copy the username to the "name" without the user knowing when they register on the site
·
Monday, 12 May 2014 01:41
·
0 Likes
·
0 Votes
·
0 Comments
·
Understood. That's a good compromise. Then when my users see the username in the name field in their profile, I can let them know that filling in their real name is optional but that the field needs something in there.
·
Monday, 12 May 2014 01:55
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks
·
Monday, 12 May 2014 12:35
·
0 Likes
·
0 Votes
·
0 Comments
·
I see that you made the name optional in the most recent release. When the user chooses not to complete the field when registering, the name is saved as the username. The user can later choose to delete the name entirely from their profile in the backend. Is this the intended behavior? It works pretty well.
·
Thursday, 15 May 2014 08:29
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi,

Yup this behaviour has been included in the latest release as promised.
·
Thursday, 15 May 2014 16:51
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post