Ticket #5111 (closed enhancement: fixed)
Make WP_User_Search class plugable
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.5 |
| Component: | General | Version: | 2.3 |
| Severity: | normal | Keywords: | has-patch needs-testing |
| Cc: |
Description
For our iPhone submission, we needed to list out all users and will eventually add search abilities. The WP_User_Search class in /wp-admin/users.php seems to do this wonderfully. Sadly, you can't include users.php as it outputs stuff.
It'd be nice if that class was pluggable for usage elsewhere.
Attachments
Change History
- Owner changed from anonymous to westi
- Status changed from new to assigned
comment:2
Viper007Bond — 4 years ago
I don't see a usage for it outside of the admin area really, and even if there is some fringe usage that requires it elsewhere, it's not hard to include() it (as we've done with other files).
-
attachment
5111.r6603.2.diff
added
Moves class WP_User_Search into wp-admin/includes/users.php and makes it pluggable
-
attachment
5111.r6603.diff
added
Moves class WP_User_Search into wp-admin/includes/user.php and makes it pluggable (Use this patch, please)
- Status changed from assigned to closed
- Resolution set to fixed
comment:6
follow-up:
↓ 7
Viper007Bond — 4 years ago
No no, props to hansengel! <3
comment:7
in reply to:
↑ 6
Viper007Bond — 4 years ago
Replying to Viper007Bond:
No no, props to hansengel! <3
Oh, it was just a copy/paste move (no code writing), but still. ;)

It sounds like WP_User_Search should be pulled out into wp-admin/includes/user.php.
Are you wanting to use the class solely within the admin? Or does it need to be available from wp-includes?