[wp-trac] [WordPress Trac] #41314: If the required fields are not save on user save, every field's value will be dropped

WordPress Trac noreply at wordpress.org
Thu Jul 13 17:43:37 UTC 2017


#41314: If the required fields are not save on user save, every field's value will
be dropped
----------------------------------------+-----------------------------
 Reporter:  jackjohansson               |      Owner:
     Type:  defect (bug)                |     Status:  new
 Priority:  normal                      |  Milestone:  Awaiting Review
Component:  Administration              |    Version:  4.8
 Severity:  normal                      |   Keywords:
  Focuses:  javascript, administration  |
----------------------------------------+-----------------------------
 Hi,

 In the user profile screen, there are some required fields such as email
 and nickname.

 Let's say I have added some extra fields using `edit_user_profile` and
 `show_user_profile` action hooks. These fields are filled by the user, and
 do not have to be required.

 If the user fills every field (let's say 20 fields, took 10 minutes to
 fill) but clears the email field and save the form, there will be shown an
 admin error:


     '''ERROR''': Please enter an email.

 Every field that was filled by the user will be dropped, and has to be
 refilled.

 The point is, until the required fields are empty, there is no reason to
 let the user save the form in the first place.

 This issue has been discussed in the WordPress Development StackExchange.
 I've posted 3 solutions for this issue, which can be improvement or bug
 resolve.

 Below is a link to the question on WPSE. I would be happy to write an
 accurate solution, in case the development team decides to push this into
 their future patches.

 https://wordpress.stackexchange.com/q/272940/94498

 King regards,
 Jack

--
Ticket URL: <https://core.trac.wordpress.org/ticket/41314>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list