Deciding which modules to use for profiles
[Update July 23, 2008: For those on D6, you might want to read this thread and learn about Content Profile, which is shaping up to be the successor to both bio and nodeprofile.]
So you want to pretty up your user profiles? But what module do you use? As with most things in Drupal, there's a lot of options. Of course, I recommend using Advanced Profile for the overall glue, but you still need some place to store the user profile data. This article will run through the pros and cons of each.
The contenders:
Bio
Usage:
Download, install, and enable the Bio module.
Setup at admin/user/bio
Add CCK fields as needed
Pros
- Integrates with the user page for both viewing and editing just by checking boxes in settings
- Uses any node type for the biography or you can extend the built in type with CCK
- Lets you link to the bio from content without any special coding
- Automatically enforces one bio per user
- Let's you choose fields from your bio node to put on the registration screen
- Designed to be lightweight and simple
Cons:
- You can have one and only one node per user which is not as flexible as nodeprofile for complex profiles
- Currently no way to have it auto create the profile node unless you put at least one field on the reg screen, but this may change soon.
- Doesn't work with some views such as in buddylist so you end up needing to use usernode as well. This may be changing soon as well.
My opinion:
If you only need one node to hold the profile data per user, I reccomend using Bio. It's simple and works well with advanced profile. You can add a lot of other information to the profile panel using advprofile so bio should work for most sites' needs.
Nodeprofile
Usage:
Install nodeprofile, nodefamily, and subform element modules
Edit the content type you want to use for your profile and tell it that it's a node profile
Edit the options on the new nodeprofile tab that appears
More complex usage can be had by having multiple content types for your profile and using pageroute to hook it all together.
Pros:
- Can have multiple content types that are node profiles which is great for complex profiles or for having different profiles for different roles.
- Lets you put your node profiles on the user view page
- Lets you add multiple node profiles to the registration page. This is nice because you can have one of your profile node types show and not others or put them all depending on your needs.
- Is part of a family of modules including usernode and pageroute that give you a ton of options
Cons:
- Unlike bio, which lets you totally take over the user page, nodeprofile just adds the profile nodes to what is there. The author considers this a pro but I, personally, don't like the looks of this, so I'm marking it as a con.
- It's complex. In order to provide the flexibility of having 1 or more profile nodes from multiple content types the setup and code is complicated.
- You need usernode as well to make it work with some views, which adds another node per user, and views fusion, which lets you merge the usernode view and the nodeprofile view is complex.
My opinion:
Nodeprofile is part of an awesome family of modules that let you do complex user profiles. If you need to get fancy with different profiles for different roles or having a wizard like process for the user to fill out multiple nodes in their profile, then this is what you want.
Core profile module
Usage:
Enable the module (it comes with Drupal)
Configure the profile by adding items in categories. Each category will show up on a separate tab of the edit account page.
Pros:
- For each field, you can control the visibility with these options:
- Hidden profile field, only accessible by administrators, modules and themes.
- Private field, content only available to privileged users.
- Public field, content shown on profile page but not used on member list pages.
- Public field, content shown on profile page and on member list pages.
- It has the ability to set a page title for a field so you can do things such as view everyone who's favourite colour is blue.
- For each field, you can set whether it shows up on the registration page.
- Editing and displaying of the profile is right on the account page with no extra work
- No additional modules to install; just enable it
Cons:
- Profiles are not nodes, which can limit flexibility, especially with views.
- According to the Lullabot podcast, the backend is a mess
My opinion:
I only briefly played with this module but it was a lot better than I was expecting. It's simple to use and has some nice options. If you don't need profiles to be nodes, this looks like a solid option. There are a lot of handbook pages dedicated to customizing it and it can do quite a bit more advanced things than I thought. Not working with views is a big drawback but that will be eliminated in D6 with views 2.
More information:
Profile: extending user account information
Customising the user profile layout
Usernode with CCK fields
Usage:
The usernode module can be used to create user profiles by adding fields to it with CCK.
Pros:
- No need to add extra modules. Just install usernode (and CCK if you don't have that) and add fields
- Usernodes are automatically created / deleted with users
- You can use views with your profiles
Cons:
- If you decide later you'd rather have multiple pages in your profile, you're out of luck
- No facility for adding the profile fields to the registration form
- Adding the profile into the user page requires jumping through some hoops
My opinion:
This option is deceptive in that it looks like the best option on the surface if you only need one node profile per user. The trouble is that you are then locked into using the usernode as your profile. If you later decide you want the extra functionality that bio or nodeprofile provide, you're out of luck. The maintainer doesn't reccomend this option and neither do I, but I'm presenting it here for completeness.
Looking to the future
What about D6? There's a possibility that bio and nodeprofile may come together for a new and improved module. Interested? See Profiles as nodes in d6 for the discussion.
If you have comments or suggestions for improving this article, feel free to add a comment. Please do not use the comments for support requests.