Pull RealName from node title (Content Profiles)

Dane Powell - June 10, 2009 - 15:34
Project:RealName
Version:6.x-1.x-dev
Component:User interface
Category:feature request
Priority:normal
Assigned:Unassigned
Status:closed
Description

I am using Content Profiles. The titles of nodes linked to Content Profiles are simply user's real names. However, because RealName can only pull information from Content Profile text fields, I have to have a separate CCK field for the user's name for use with RealName. Thus, users have to type their name in twice on their profile, which is a little silly. It would be great if RealName could pull from node titles in addition to text fields.

#1

nikolajb - July 5, 2009 - 16:28

I'm looking for exactly the same thing, as I'm pretty sure that my users would complain about having to type in the same information twice in their profile. An alternative solution could be to create a hidden text-field that defaults to the same value as the profile name and then hiding that field from the user. But I still think that adding profile name-support would be the correct solution (also, I couldn't get my own work-around to work, so as an alternative, I'd love to hear exactly how that could be done :) )

#2

NancyDru - July 5, 2009 - 16:49
Status:active» postponed (maintainer needs more info)

Have you considered http://drupal.org/project/Auto_Nodetitle and only using the name field rather than a title?

I have a site that does exactly this. The "Pattern for the title" is [field_salutation-formatted] [field_firstname-formatted] [field_middlename-formatted] [field_lastname-formatted] [field_suffix-formatted]

#3

nikolajb - July 5, 2009 - 17:51

Thanks! Solves my problem :)

The answer to your question is yes and no: I had considered hiding the node title, but didn't realize that I needed a module to do that. Obviously, I should have know that you _always_ need a module to change anything in Drupal :)

Once again, thanks for your help.

#4

NancyDru - July 5, 2009 - 23:07

That's the short-term easy answer here. I have a site that does similar (which is how I could show the pattern), so I could give an answer that gets you going. The idea has merit, and I will see if it is possible to add the title to the list of available fields without a lot of circuitous coding.

#5

Dane Powell - July 6, 2009 - 21:03

Node Auto Titles is an okay stopgap solution, but it has problems of its own- mainly, it restricts you to only creating Content Profiles for site users. Sometimes I need to create profiles for people who aren't necessarily users, and this isn't possible because the title is hidden and can only be generated from a site user.

#6

NancyDru - July 7, 2009 - 15:34
Status:postponed (maintainer needs more info)» fixed

Under the general settings there is a checkbox to allow the title to be available. Then go to "Fields" to select it.

Committed to -dev.

#7

Dane Powell - July 8, 2009 - 22:51
Status:fixed» needs work

Sorry to reopen this issue, but the fix is not working for me. I check the option to make the Node title available as a field, choose the "Content profile" module, select the "Node title" field and then rebuild the realnames, but no RealNames appear throughout the site.

Let me know if you need help reproducing this issue.

#8

Dane Powell - July 8, 2009 - 22:53

I don't know if this is relevant, but I noticed on the fields page the following line:

"You are using the content_profile module to provide fields.The profile type is the source of data."

Is the profile module going to provide the titles of Content Profile nodes?

#9

NancyDru - July 8, 2009 - 23:42

No, it is saying that your content type is named "profile".

#10

Dane Powell - July 9, 2009 - 02:42

I see- my mistake. Anyway, I'm really not sure why this isn't working then...

#11

Dane Powell - July 29, 2009 - 22:07

I can pull other fields from that content type, but I still cannot pull the Node Title. Any thoughts?

#12

a_c_m - August 21, 2009 - 08:02

+ 1 for wanting to see this.

#13

Boris Mann - September 3, 2009 - 05:43

Great solution, thank you.

#14

wilgrace - September 12, 2009 - 13:02

I've been trying to get this to work too, and it's not happening - other Fields can be pulled in as Real Names, but after checking the box for 'Use Node Title' from Node Profile, and selecting the Title in 'Fields', rebuilding the names doesn't use the Title. Checking the database shows that it's reverted to usernames.

It may be unrelated, but two other issues I'm getting:
- The rebuild seems to fail after around 80%. However, using normal Fields, real names are assigned to the users in the db table so all seems to go through
- 'Overwrite user fields in view to show realnames' will accept a check, but on Submit it reverts to unchecked and doesnt alter Views

Using the latest dev version. This is an awesome module - I dont understand why this isn't committed to core.

thanks

#15

NancyDru - October 1, 2009 - 15:30
Status:needs work» fixed

Fixed by #579040: Some bugfixes.

#16

NancyDru - October 14, 2009 - 23:12
Status:fixed» closed

Included in 6.x-1.3

 
 

Drupal is a registered trademark of Dries Buytaert.