How can I create a subsite in a Multisite WordPress installation with a PHP script?
I’ve read about wpmu_create_blog()
but I don’t understand how use it.
I receive this error:
Fatal error: Call to undefined function wpmu_create_blog()
How to solve this?
The part you miss is in this Q&A: Creating new blog using PHP. Summed up in an example, adjust the domain and type of Multisite. For testing purposes only, don’t leave this file in your live server.