Problem with Hebrew characters in username

I wrote a plugin to enable hebrew characters in usernames. This is the full code: add_filter (‘sanitize_user’, ‘hu_sanitize_user’, 10, 3); //Overrides the WordPress sanitize_user filter to allow hebrew letters and english letters only function hu_sanitize_user ($username, $raw_username, $strict) { //Strip HTML Tags $username = wp_strip_all_tags ($raw_username); //Remove Accents $username = remove_accents ($username); //Kill octets $username … Read more

Why can’t I update username through WordPress API?

I’m just wondering about usernames… Why isn’t is possible to change this through WordPress API? (I understand why a user in the admin dashboard can’t change username(s) but that isn’t really same thing!?) Code below does just ignore the user_login – setting. $pupil_obj= get_post($postid_pupil); $user_login = $pupil_obj->post_name; $user_nicename = $pupil_obj->post_name; $user_args = array( ‘ID’ => … Read more

Displaying Logged-In User Name in WordPress Menu

I’m using WordPress with UserPro, and want my menu to display the logged-in user’s first name, linked to the user profile page. The problem is that in my menu structure, the “Profile” menu option is supposed to have a sub-menu containing “edit profile”, “submit”, and “logout”. This is the code I’m currently using: /*earlier code, … Read more