[wp-trac] [WordPress Trac] #42249: "Add Existing Users" -Form on Multisite still shows up after remove Capabilities to see it

WordPress Trac noreply at wordpress.org
Sun May 27 19:01:30 UTC 2018


#42249: "Add Existing Users" -Form on Multisite still shows up after remove
Capabilities to see it
--------------------------------+------------------------
 Reporter:  tqmtqm89            |       Owner:  (none)
     Type:  defect (bug)        |      Status:  closed
 Priority:  normal              |   Milestone:
Component:  Networks and Sites  |     Version:  4.8.2
 Severity:  normal              |  Resolution:  duplicate
 Keywords:  reporter-feedback   |     Focuses:  multisite
--------------------------------+------------------------
Changes (by jeremyfelt):

 * status:  new => closed
 * resolution:   => duplicate
 * milestone:  Awaiting Review =>


Old description:

> Hey there,
> i got a Multisite where it should be possible for Administrators (not
> Super-Admins) to add new Users to their subdomain. But i'd liked to
> disable the option to add existing users.
>
> So i customized the capabilities for my plan and it seems i have found a
> bug cause it just worked half the way.
>
> From before changing the capabilities the state was:
> [https://i.imgur.com/KKXaUgQ.png]
>
> After change of capabilities just the headline was removed (i highlighted
> it in the screenshot above)
> [https://i.imgur.com/m9cEY0p.png]
>
> So what i wanted to create was something like
> [https://i.imgur.com/hZxjsoA.png]
>
> So i moved deep into Wordpress-Core and found the possible bug and fixed
> it so far for me:
> [https://i.imgur.com/lKXVkzZ.png]
>
> i added the if clause around the form that check the $do_both on line 326
> + 377 on the wp-admin/user-new.php.
>
> At the moment in line 314 is it checked but only hide / show the headline
> of add existing users but have no influence to the form.
>
> Greetings from Paderborn

New description:

 Hey there,
 i got a Multisite where it should be possible for Administrators (not
 Super-Admins) to add new Users to their subdomain. But i'd liked to
 disable the option to add existing users.

 So i customized the capabilities for my plan and it seems i have found a
 bug cause it just worked half the way.

 From before changing the capabilities the state was:
 [https://i.imgur.com/KKXaUgQ.png]

 After change of capabilities just the headline was removed (i highlighted
 it in the screenshot above)
 [https://i.imgur.com/m9cEY0p.png]

 So what i wanted to create was something like
 [https://i.imgur.com/hZxjsoA.png]

 So i moved deep into WordPress-Core and found the possible bug and fixed
 it so far for me:
 [https://i.imgur.com/lKXVkzZ.png]

 i added the if clause around the form that check the $do_both on line 326
 + 377 on the wp-admin/user-new.php.

 At the moment in line 314 is it checked but only hide / show the headline
 of add existing users but have no influence to the form.

 Greetings from Paderborn

--

Comment:

 Duplicate of #37836.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/42249#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list