Opened 9 years ago
Last modified 6 weeks ago
#38750 new feature request
Split wp_signups into wp_user_signups and wp_blog_signups
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Awaiting Review | Priority: | normal |
| Severity: | normal | Version: | 3.0 |
| Component: | Login and Registration | Keywords: | 2nd-opinion needs-screenshots needs-unit-tests needs-patch |
| Focuses: | multisite | Cc: |
Description
Right now, wp_signups (and the entire related API) does double-duty. It's 1 database table that's used for both users & blogs, but there are a few issues with this approach:
- Open sign-ups may or may not include ability to create sites
- There is no UI for managing sign-ups in WordPress core
- Sign-ups are different between singlesite & multi-site
- Plugins like BuddyPress do their best to include and/or work-around WordPress's core functionality, but end up writing a ton of additional code to manage this
- Other membership plugins are forced to roll their own approach every single time
- It's possible for multisite sign-up race conditions to exist, with users & sites created or activated from underneath each other (documented in
wpmu_activate_signup())
I'm adding the multisite focus to this issue, because all of the current code is only relevant to multisite, but I'd like to see single-site inherit whatever future approach we can come up with.
The core sign-ups code, stinks. Yet open registration is part of what makes WordPress & community/membership sites great. I think it would be great to take what we've learned from BuddyPress, WordPress.org, WordPress.com, and the bevy of Membership plugins, and make a great sign-up component/API for WordPress core.
Change History (6)
#3
@
9 years ago
+1 on this needed refactoring, it will be far easier to deal with signups with this approach.
This ticket was mentioned in Slack in #core-multisite by florian-tiar. View the logs.
9 years ago
#6
@
6 weeks ago
What is the status of this? I'm writing because I'm trying to learn something/anything about why the wp_signups table exists. I have a multi-site, and I have a few legitimate users in this table who are noted as active. But 95% of the users are spam and I don't know how they are being added to this table. Can you please tell me what URL they are going to to add themselves?
An alternative would be to ditch
wp_signupsall together, and addstatusandcreatorcolumns towp_blogs.Then, when a user is activated, the process would be:
wp_users::user_activation_keyuser_statusfrompendingtoactivewp_blogs::statusinpendingwith a matchingcreator_idto thewp_users::user_idwp_blogs::statusfrompendingtoactiveThis has the net positives of:
...at the cost of...
wp_signupsis going awaySee also #34316.