Skip to:
Content
Pages
Categories
Search
Top
Bottom

Unable to edit profile since WordPress 4.4.1 in frontend


  • klantomo
    Participant

    @klantomo

    After the update from WordPress 4.3.1 to 4.4.1 I receive the error message “ERROR: Please enter a nickname.” when I try to change any profile field in the bbpress profile frontend.

    I was able to verify the bug without no other plugins enabled. I also verified that the bug does not exist in WordPress 4.3.1.

    Is this a WordPress or a bbpress bug?

Viewing 1 replies (of 1 total)

  • tharsheblows
    Participant

    @tharsheblows

    This is a result of a change in WordPress. I had this too – I don’t allow users to change their nickname so the nickname field on the edit form was disabled and didn’t submit (as was the intent). What I did was make the nickname field “readonly” rather than “disabled” and then added this in (you could add it to your functions.php)

    user_nickname_is_login( $meta, $user, $update ){
    	$meta['nickname'] = $user->user_login;
    	return $meta;
    }
    add_filter( 'insert_user_meta', 'user_nickname_is_login', 10, 3 );

    This sets the nickname as the user_login so you would change it to whatever the nickname should be. That function forces the nickname to be what I want — I know the field in the profile was readonly but it was still editable using dev tools and I didn’t want that!

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.
Skip to toolbar