I want to create a content type in which one of the field is a list of all users in drupal.I know I can add a node reference field but that reference is showing only normal node view but not user view.Is there a way to add list of all users in a content type?


You can create a Users view, using a module called Views. It's not exactly "content" (node) but Views can create Page displays which can be placed on the menu.

  • @:Baysaa:Yes...we can create a view.but while creating a view we have to select the type of view.a view cannot be referred if it is of type 'user' in cck. But to what I know only user type views can can generate a list of user view. is there any other way to create a node type view with a list of users in drupal? – C-3PO Mar 16 '12 at 11:50
  • Sorry misunderstood your question. Sounds like you need "User reference" field on your node. It comes with CCK module. You need to enable it from Modules page. Then you can add a "User Reference" type field to your node. And create a "Node" view, add a "Relationship" on the view and select your User reference field for that relationship. Now on the "Fields" area of the view you can add fields like "User: Name" or "User: UID" and after you add them, on the settings of that Field you can select a relationship. Select the relationship you added. Hope this helps. – Beebee Mar 16 '12 at 12:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.