wp-calypso
wp-calypso copied to clipboard
User Profile: Editing biography, display name and so on in WP Admin isn't possible.
Quick summary
Following this PR - https://github.com/Automattic/jetpack/pull/20479
This has created a situation where any user who has previously edited their profile details from WP Admin can no longer access the fields to edit them with SSO enabled.
The options are to either update the WordPress.com profile or to disable SSO so the fields are then available in WP Admin.
This is problematic for users with multiple sites since the only option for them to now have separate author information for multiple sites is to not use SSO or to have multiple WordPress.com accounts with separate user information.
Ideally, we should consider a way so it's always possible to have separate profile information for individual sites on an account for that user to make management easier.
Steps to reproduce
- Disable SSO and then edit the user biography and display name for a site
- Enable SSO and notice there is no way to edit these fields anymore except by changing the user profile in WordPress.com
What you expected to happen
To be able to still have a way to change user profile details per site
What actually happened
It's only possible to change the profile details with SSO disabled or by having multiple accounts with different profile info.
Context
4327524-zd-woothemes
Operating System
No response
Browser
No response
Simple, Atomic or both?
Simple, Atomic
Theme-specific issue?
No response
Other notes
No response
Reproducibility
Consistent
Severity
Some (< 50%)
Available workarounds?
Yes, difficult to implement
Workaround details
There are 2 workarounds:
- Disable SSO
- We can change this for the user directly on the site using internal tools
- Create a new WordPress.com account to handle different profile info
Related discussion: p9GEWz-OB-p2
Flagging this for Flow Patrol Manage to take a second look. Also pinged in the P2 post.
Another report: 32868074-hc
Reported in #4857204-zen
Reported here in 5241009-zd-woothemes
Profile description not updating 25074156-hc
Workaround: I updated their profile description in CLI.
Support References
This comment is automatically generated. Please do not edit it.
- [ ] 4327524-zen
- [ ] 4857204-zen
- [ ] 5241009-zen
- [ ] 6176310-zen
- [ ] 8262381-zen
Another:
- [ ] 6176310-zd-woothemes
One more case: 8262381-zen
Shared a code snippet that would allow the user to edit the Author Bio directly in Users > Profile (ie https://site.com/wp-admin/profile.php)
add_action('show_user_profile', 'add_user_description_field');
add_action('edit_user_profile', 'add_user_description_field');
function add_user_description_field($user) {
$description = get_user_meta($user->ID, 'description', true);
?>
<h3>Author Bio</h3>
<table class="form-table">
<tr>
<th><label for="description">Author Bio</label></th>
<td>
<textarea name="description" id="description" rows="5" cols="30"><?php echo esc_textarea($description); ?></textarea>
</td>
</tr>
</table>
<?php
}
add_action('personal_options_update', 'save_user_description_field');
add_action('edit_user_profile_update', 'save_user_description_field');
function save_user_description_field($user_id) {
if (current_user_can('edit_user', $user_id)) {
if (isset($_POST['description'])) {
update_user_meta($user_id, 'description', sanitize_text_field($_POST['description']));
}
}
}
Set the snippet to Only run in administration area and press Save Changes and Activate.
It would look like this:
I think this is no longer an issue now that we have untangled Calypso and Bios can be edited serparetly on local sites... right @fushar @taipeicoder?
I am going to close this but feel free to reopen if necessary.
@mrfoxtalbot, thanks for the timely ping. We recently tried to make those display name / bio -related fields untangled for all sites as part of pbxlJb-63Y-p2... but we ran into a rabbithole, documented here: pbxlJb-67I-p2. In summary:
- We found confusing inconsistencies between untangled (local) user profile vs wpcom (Gravatar) profile. One is used for displaying post author and another is used for displaying comment author.
- It is inconsistent between Simple and Atomic.
- It is weird that we have untangled display name/bio but only a single Gravatar image (avatar) per email.
This is confusing even for developers when testing the behaviors (we did some kind of internal personal walkthrough before planning to do usability testing). We considered this as "bug" / missed case from the Untangling Calypso project.
In short -- for Classic sites, we re-tangled those user profiles back so that the source of truth is /me. We ran out of "appetite" (time budget) for this project. In the future, if we want to try untangling these fields again, we need to take this Gravatar commenting journey into account.
P.S: just to confirm that all the above only apply to wpcom users. For example, local Atomic users already able to set them per-site.
cc: @okmttdhr
Thank you for the super derailed explanation @fushar.
I'll come back to this to ensure it's documented and HEs are in the loop.
Coming back to this @fushar, I noticed we added some details alongside a direct /me link for the email and name ("You can modify your profile..."):
Is there a reason why we have not done the same for the Bio section to avoid confusion?
If this was an oversight, can we include that same message there?
Thank you!
The idea is to co-locate all fields that are managed on /me to a single notice. It includes Contact Info -> Website and About Yourself -> Biographical Info:
The "more correct" way is to keep the above two fields and add a notice on each of them. However, that will make the page very crowded with links. What do you think?
Mmmm... I agree that it does not look great but i feels inconsistent to add the notice only to some fields. This is what I see now:
Is this what we are going with @fushar?
Is this what we are going with @fushar?
Yeah, this is the existing production behavior; a compromise between correctness and conciseness. 😅
Got it. Thank you @fushar. I included this in our revision of SSO docs.
As we work on untangling from Calypso, I'd like to suggest reopening this issue.
Right now, one can only customize their WordPress.com account biography in Calypso. This proves problematic when used with the site editor's wp:post-author-biography block, in author archive templates.
That block pulls data from the user's biography set for the site. It makes sense, but that option cannot be edited on a WordPress.com site because we redirect to Calypso instead.
On top of the issue with the site editor, it also proves problematic when folks want to have different biographies on different sites (in different languages for example).
OpenAI suggested the following labels for this issue:
- [Feature Group] User Management: The issue involves managing user profile details, which falls under user management functionalities.
- [Feature] Authentication: The problem is related to users being unable to modify their profiles due to Single Sign-On (SSO) settings, which is part of authentication features.
- [Feature] User & Account Settings (/me): The issue directly concerns user account settings where profile information is edited in WordPress.com.
@Automattic/zenith fyi while you're looking at untangling site users.
I’m closing this issue as we have decided NOT to support site-level profiles for these fields on WP.com. For more details, please refer to this comment and discussion: pfYzsZ-1JU-p2#comment-1629.