Associate an user to a taxonomy term


User profiles are fieldable in Drupal 7, you can add a taxonomy field already, with nothing but core. You don't need Entity Reference or any other modules, you can simply add field_taxonomy to your user. Sure, it is a bit opposite to "add users to terms" you described, but later, if you need it for Views etc, it doesn't matter which way it was created - there is a connection between user and term, and you can use it.

Similar questions

Associate webform submissions with the user created
I am allowing anonymous user create submissions, and creating a user programmatically based on these submissions. How do I associate this submission with the user I've just created? UPDATE: I thought I could use db_update for this but I'd be interested to know if there is a more functional way.
How to associate the last image from gallery to user's profile picture
In Drupal 7 (Commons 7.x-3.46). I've created a new content type, by which each user can upload images and build a personal picture-gallery. How can I now associate the last-uploaded-image to the user's profile-picture? Amodule-based solution is preferable. Is there a better way of doing this, ie without a new content type? Essentially I'm looking f...
How to associate multiple profiles per user with Profile2
I'm running a Drupal 7 site that has different profile types (created using the Profile2 module). Each user is associated with a profile, so at the time of registration, a potential user can choose a specific profile, and based on that, a different registration page is displayed. I was wondering, is it possible to allow a normal user (not admin) to...
Associate Every Displayed User Name With Corresponding Table Row
Updated: I would like data from the table displayed with every "User Name" however it is displayed. As an example, I have this in hook_preprocess_page_title(): The route entity.user.canonical allows me to reference the viewed user, and so I can use \Drupal::routeMatch()->getRawParameter('user') to get the non-current user ID. (it's no...
What is causing /user/*/taxonomy/term/* to redirect to /taxonomy/term/*?
I got a view with contextual filters set up as the following: When I go to*/taxonomy/term/* I'm being redirected to*. How can I prevent this? I also got Pathauto to change the URLs to [user:name] for user/* and tags/[term:name]for taxonomy/term/*. Edit: If I disable the URL alias for the taxonomy terms it ...
Make taxonomy term only link to term page if multiple nodes have that term?
I have a free tagging taxonomy term field. How can I make it so on the node page the term only links to a term page if there are multiple nodes with the same term? Otherwise this link and page are pointless, and are bad UX as the user will be expecting to see other similar nodes. So if there is only 1 node with a term then I would like the term to ...

Also ask

We use cookies to deliver the best possible experience on our website. By continuing to use this site, accepting or closing this box, you consent to our use of cookies. To learn more, visit our privacy policy.