Support » Networking WordPress » Automate Creating Sites In Multi-Site Programmatically

  • Howdy,

    What is the best way to hook into our multisite install and create new sites dynamically (through php)? We don’t want to use the provided sign up page, we wish to use our own separate website and simply set the form action to a script we create to automate the setup.

    Is there a RPC we can call, or a php function?


Viewing 7 replies - 1 through 7 (of 7 total)
  • Bump. I would think this would be super common. Instead of using wp-signup.php we wish to use our own static page, and simply pass data.

    Basically looking for a way to do this remotely, after some googling, seems like the API or calling wp_remote_request() might work, but what would I pass? How would this work?


    Moderator Ipstenu (Mika Epstein)


    🏳️‍🌈 Halfelf Rogue & Plugin Review Team Rep

    Don’t bump. It’s against the rules.

    What’s wrong with the wp-signup.php page? Are you trying to add more options to it, or what?

    Sorry bout the bump. Yeah, the biggest thing we want to implement is a custom invite code. We also want to completely re-style, but that can be done in WordPress with the theme.

    Is there a way for us to extend wp-signup.php and add another field invite, which then should check a custom table to verify the invite code is valid?

    Justin, I’m thinking you could go with provisioning with WHMCS and having that set up that. It may be overkill but whmcs is a great way to manage your network.

    Yeah, don’t need the bloat of WHMCS. We’ve already setup the infrastructure, nginx+php-fpm+apc+memcache and dual MySQL master-master replication (load balanced).

    I think we may be able to mod wp-signup.php, just need to add the invite field.

    If you do actually want to implement the signup process yourself, you can use WordPress’ wpmu_create_blog() function.

    Take a look at the validate_another_blog_signup() function inside wp-singup.php if you want to see how it uses wpmu_create_blog().

    You’ll more than likely have to include/require wp.load.php before you can use those functions.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Automate Creating Sites In Multi-Site Programmatically’ is closed to new replies.