Topics related to users, their user profiles, etc.

learn more… | top users | synonyms (6)

0
votes
0answers
11 views

Can a person that doesn't have access to a page, view an unpublished article to review?

Can a person that doesn't have access to the backend of my website view an unpublished page? I.e I want to set up an article but need someone to review before I can publish it. I can't give this ...
1
vote
3answers
18 views

How to send an email to a specific user on new account creation using Rules?

I have an alumni association portal. When a new user creates profile on the portal, that account stays blocked until a specific user from that batch/department approves it. I am trying to make use ...
1
vote
5answers
44 views

How to show a user login form on a completely separate page?

I am developing a application where I want to restrict everything from anonymous users. If anyone tries to access any page from url directly they will be redirected to login page. How to do this? ...
2
votes
0answers
11 views

How do I multisite with share user (and SSO), separate/dedicated users' role and content database on each site

I like to make Drupal 8 in CentOS 7 with Apache 2.4, mySQL and PHP 5.6 environment with requirements: Multi-site within domain (site0.example.org, site1.example.org, etc.) Shared local user account ...
-1
votes
0answers
24 views

Manipulate login Form in Drupal 8 [on hold]

I want to manipulate user login form(add email)in Drupal 8,I tried with this link http://www.foreach.be/blog/how-manipulate-forms-drupal-8 but no result , I want the form appears on my site with a ...
1
vote
1answer
17 views

An explanation on user_save() works

I was writing on a module for drupal and i had to update some fields in the user-object. I first tried this code: $account = user_load($user->uid); // Loading account $edit = array( ...
0
votes
0answers
8 views

User can't change their own location after registration anymore

i'm using the loaction module for user locations. At the registration form a new user has to enter his oder her location and it will be displayed in his profile. When the user tries to edit his or her ...
1
vote
1answer
9 views

User Folder Access Control

I work at a university that has switched to Drupal. We have several hundred departments making their own "sites" in our system. Most departments need to be able to upload and change ONLY their own pdf ...
1
vote
2answers
23 views

How to separate 403 path per role?

On admin/config/system/site-information, one can specify "Error pages" for 403 (No access) and 404 (Page not found). It would make a lot of sense to specify different pages here, depending if you are ...
-1
votes
1answer
41 views

How to create a User search view?

I am trying to create User search view (using Views). But when I create the view, I am not able to see the search option in filter. What I am missing?
2
votes
2answers
24 views

Understanding `file_usage` table

I am trying to understand the Drupal database schema because I need to access the database via MySQL by another system and I do not have access to the original Drupal developer of the site nor do I ...
2
votes
1answer
26 views

How to use current user object in Drupal 8? [duplicate]

The answer to "Is there a function to get the current user object that avoids accessing the global variable?" includes this: In Drupal 8, you simply use the static method \Drupal::currentUser() ...
0
votes
1answer
14 views

Username converted to us-ascii (unix-style)

I want to convert unicode characters in user names to us-ascii. I.e my first name is Søren and my last name is Sjøstrøm. It should be converted to soren.sjostrom (unix style) as the user name. How do ...
0
votes
1answer
15 views

Get created term entity after creating term programatically

I'm writing a custom Drupal Console command to import user data from a text file and create users, and as part of the process, I need to add data to a term reference field. In the case that a term in ...
0
votes
0answers
30 views

Multi-step form using hook_form_alter()

I am building a User registration form. My requirements for multi-step form: STEP 1- Here government/register is unique registration path from Profile2 Registration Path module function ...
0
votes
1answer
8 views

Attach a Webform to user registration form

Is there any way to do this in Drupal 7? I want new users send some documents via Webform on registration. The reason is that I don't want to save these documents as an user profile field.
-1
votes
1answer
27 views

How can I see anonymous visitors in real time Google Analytics? [closed]

I can't see anonymous visitors in real-time in Google Analytics, I can only see registered users. But I need see all visitors in Real-time>Overview , including anonymous visitors. In the Google ...
1
vote
1answer
24 views

Unsubscribed from Simplenews Newsletter

is there a way to find how many users unsubscribed from my Simplenews newsletter at my Drupal-7 website? And, if yes, can I detect from which particular newsletter did the user unsubscribe from?
0
votes
0answers
5 views

How to check if an image field in core profile has data using computed field

I created a new image field in Core profile named 'field_userimage'; then, I created also a image field in Node content type named 'field_nodeimage' ; at the end, I created a Computed Field to show ...
1
vote
1answer
27 views

How to send a notification to admin on profile picture change?

I want the new uploaded pictures to be sent (notification) to me (admin) for review and approval just to be sure they are in line with the terms and conditions of the webpage. Naked or semi-naked ...
0
votes
0answers
16 views

Multisite with separate DB but shared user accounts

I'm wondering if it is possible to create multi-site programatically (through custom module) where user can register account themselves and then create site. Database has to be separated but user ...
1
vote
2answers
31 views

How to implement moderation of data entered through user profile pages?

I am in need of a means of moderating data entered through a user's profile page, or at least for certain specified fields, both upon initial submission and after any revision. These are fields that ...
0
votes
0answers
30 views

User can't edit user profile picture

Drupal 7 Users can't edit their own profile pictures. The admin can edit them, but the regular user cannot edit his own. A user can see their own picture, but if they click the Edit tab it is not ...
3
votes
1answer
35 views

How to verify only the email address on user registration?

I have a registration form. On the registration form the user can enter his username, email address and password and confirm password. When the user registered, he/she should receive an email to ...
1
vote
2answers
76 views

How can I show menu according their role?

I have three roles Business Manager, General Manager and Handler. How can I show only specific menu according their role?
1
vote
3answers
73 views

Is it possible to login to Drupal with a custom user field, instead of username/pass?

I have two websites - One of them is Drupal 7, and the other is a different site (Site #2). In Site #2, within the user tables, is a field called "customid". Each user on Site #2 has a unique, ...
0
votes
1answer
22 views

Fetch user's realname (from Name Field) within database query (or an alternative method)?

I'm building a custom field for a form based off of the values stored in a user reference field. The options for this field are being built from the following database query: <?php // Fetch the ...
0
votes
0answers
7 views

How show core user mail if node author not anonymous using Computed field

I'am trying to set a computed field that: 1) show the core user email address if node author uid !=0; 2) and when the node author uid=0, no core user mail address can be find, so I show instead a ...
2
votes
5answers
42 views

Show users a different page (depending on their role) after logging in [duplicate]

In my site I have two different roles for users named recruiter and candidate. when they register their account they can choose their role (recruiter or candidate). And when they login my site I will ...
0
votes
1answer
17 views

Is it important to reset the $user object when accessing global $user?

I see that some developers reset the $user object in a manner similar to the following: function my_example_callback($args) { global $user; $account = $user; $user = user_load(1); // Bypass ...
0
votes
1answer
28 views

Programmatically update or add a user's avatar

I'm trying to update the user avatar in my custom module. Which method shall I use to update the image in db as well as to move the file to public directory? Thanks.
1
vote
1answer
46 views

How do I get users by role programmatically

In Drupal 8 I need to get all users by given role name.
0
votes
2answers
39 views

How can I find user role based on user id? [closed]

There are many user list. My need is to find out user role based on their user id.
0
votes
1answer
16 views

Does the $form['element']['#disabled'] = TRUE guarantee that the user cannot edit the field or is it just a UI setting

I have a form element like this: $form['title'] = array( '#type' => 'textfield', '#title' => t('Subject'), '#default_value' => $node->title, '#size' => 60, '#maxlength' ...
0
votes
0answers
14 views

How can I configure Google Adsense crawler access for authenticated pages?

If using Google Adsense on pages that only authenticated users can access, then you have to give the Adsense crawler access in Adsense -> Settings (gear icon) -> Access and authorization -> ...
0
votes
1answer
8 views

How can an address database be converted to an account profile?

I imported an address database into Drupal as a content type and I want to convert into an account profile, with users having the ability to make changes it, and use some of the fields in it to link ...
0
votes
0answers
19 views

user_delete deletes anonymous users uid

I have used user_delete_multiple($uid) with an empty array of $uid being passed.It resulted in deleting anonymous user's uid from users table resulting in error everytime an order was placed. I am in ...
2
votes
3answers
94 views

How to create a list of users according their roles? [closed]

How can I create/see the list of user according their roles? I'm interested in any answers to do this programmatically, or via any other way/technique I could use for this.
1
vote
0answers
26 views

Creation of users and see list of the user created by a specific roles like? [closed]

I have three kind of role business manager,gen manager and handler. Business manager can create an account for gen manager and activation will done automatically. My requirement is that How can ...
3
votes
2answers
26 views

Is it safe to use a custom value for users.status column

Currently status column can have only 2 values: 0 - inactive 1 - active I need to add a new status for the user: temporarily inactive. Will it be safe if I use status = 2 for it?
0
votes
0answers
10 views

Passing personalized values from PHP to authenticated users by drupal_add_js (by Drupal.settings object)

Is it possible to set personalized variable values for authenticated users using the Drupal.settings object, using this code: drupal_add_js(array('modulename' => array('key' => 'value')), ...
-1
votes
1answer
25 views

Role creation in drupal at multi level? [closed]

I want to create to some role as business manager,manager and last is handler. Business manager should have the role who can create manager user . Manager role should have the privilege who can create ...
0
votes
0answers
28 views

Drupal 8 register link?

I have a clean Drupal 8 install with bootstrap theme. I just want to add a simple link to the registration form in the user account menu and to it only be visible if you are not logged in. The login ...
4
votes
2answers
97 views

Creating an alternative login page other than /user/login

I have managed to do this in Drupal 7 with the following code: function my_special_paths_menu() { $items['authenticate'] = array( 'title' => 'Log in', 'page callback' => ...
3
votes
1answer
56 views

How do I programmatically create users?

I need to create users in code specifying password, email and other fields' values. How can I achieve this?
2
votes
2answers
60 views

How create a role that only can create users?

I want to create a role in Drupal. I want create role assign to specific user. Specific user can create only user and not anything.
1
vote
0answers
33 views

Content acces basing on a field value

In Drupal 8, how do I give access to some nodes to users with specific roles, depending on a field value or a taxonomy value?
3
votes
2answers
54 views

How to give users with role Role2 the right to edit only user accounts with role Role1

I need to make a user edit users that have a specific role. In fact we have two user roles here. Role1 -> is able to edit a particular kind of node Role2 -> is only able to administer users with ...
5
votes
3answers
185 views

How to award userpoints to referring users?

I am creating a referral program on Drupal. I have almost everything working right except awarding userpoints to users. I want to award userpoints to users after the person they refer to the site ...
0
votes
2answers
16 views

One time URL doesn't re-direct the user to change the password

In Home » Administration » Configuration » under the email messages section when a user is invited to the site the [user:password] is not generated and the one-time-login URL doesn't re-direct the ...