Title: User role NONE
Last modified: June 5, 2020

---

# User role NONE

 *  [alexsimfi](https://wordpress.org/support/users/alexsimfi/)
 * (@alexsimfi)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/user-role-none-4/)
 * Hello everyone!
    My question is: new users are registered on the site using a
   PHP script through the wp_insert_user () function. Moreover, the form has a choice
   of standard roles. But new users are assigned the role of only NONE, regardless
   of the choice in the form. Why is this so? The test shows that the role variable
   is passed to the server. WordPress only assigns NONE.
 * Thanks for the help.
 * Yours faithfully,
    Alexander

Viewing 1 replies (of 1 total)

 *  Moderator [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/)
 * (@sterndata)
 * Volunteer Forum Moderator
 * [6 years, 2 months ago](https://wordpress.org/support/topic/user-role-none-4/#post-12944470)
 * It sure sounds like there’s a problem with your PHP script. Try dumping (print_r
   or var_dump) the $user array before calling the function and test the return 
   for an error.
 * [https://developer.wordpress.org/reference/functions/wp_insert_user/](https://developer.wordpress.org/reference/functions/wp_insert_user/)

Viewing 1 replies (of 1 total)

The topic ‘User role NONE’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/user-role-none-4/#post-12944470)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
