Make WordPress Core

Opened 8 years ago

Closed 16 months ago

Last modified 14 months ago

#20592 closed enhancement (worksforme)

Add hooks to New Site form in Dashboard

Reported by: MadtownLems Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.4.3
Component: Networks and Sites Keywords: bulk-reopened close
Focuses: multisite Cc:


WordPress provides hooks for altering the wp-signup.php form that users use to create new sites on a MultiSite network. Using these, we developed a plugin that adds fields there for people to indicate some other information about their site. (specifically, to choose a topic)

However, there are no such hooks available on the New Site form available to network admins via the dashboard for some reason. This means that I am not able to append the extra form fields here that I can on the wp-signup.php page.

There should be similar (or identical) hooks used here so the New Site form can be modified in a similar way and be consistent with the wp-signup.php form.

Change History (13)

#1 @scribu
8 years ago

  • Cc scribu added

#2 @DrewAPicture
8 years ago

  • Cc xoodrew@… added

#3 @bananastalktome
8 years ago

  • Cc bananastalktome@… added

#4 @Ipstenu
8 years ago

  • Cc ipstenu@… added

#5 @martythornley
8 years ago

  • Cc marty@… added

#6 @martythornley
8 years ago

One of the tough parts here is that the html is completely different, so you would need to add different things in each place. It would be great to somehow get them working in a similar way.

#7 @jeremyfelt
7 years ago

  • Milestone changed from Awaiting Review to Future Release

Agreed that hooks should be available in the new site form. I'd lean toward rethinking the experience of the new site form in general before we decide where to add the hooks. A patch as an example of where a hook could be useful may start things off as well.

#8 @jeremyfelt
7 years ago

  • Component changed from Multisite to Networks and Sites
  • Focuses multisite added

#9 @helen
7 years ago

If/when this becomes a thing, we should revisit adding required field indicators to the form: #15765.

#10 @jeremyfelt
5 years ago

  • Keywords needs-patch added

Related #14215 and #31240, which this ticket could eventually compliment as part of a new Add Site interface.

This ticket was mentioned in Slack in #core-multisite by richardtape. View the logs.

5 years ago

#14 @Mista-Flo
16 months ago

  • Keywords bulk-reopened close added; needs-patch removed
  • Resolution set to worksforme
  • Status changed from new to closed
  • Version set to 4.4.3

There is an action hook since 4.5 just before the submit of the form, so you can easily add some custom HTML inputs.

         * Fires at the end of the new site form in network admin.
         * @since 4.5.0
        do_action( 'network_site_new_form' );

Note: See TracTickets for help on using tickets.