Using the latest version of wpmu.
I have a membership site and I would like to give users there a free blog as a bonus to their membership. This means that I wouldn't like people to just sign up for a new blog on my blog farm site. I also don't want to have to manually add each new user to the blog site.
What I was hoping to be able to do was programatically create a user account based on their login to my membership site and then enable users to create new blogs. Please tell if there's some way to do this.
Thanks.
Site Admin -> Options and find "Allow new registrations"
check "Only logged in users can create new blogs."
Then, as a bonus when they've paid, give them the link to the signup page. When they are logged in, they'll get a greeting and fields to fill out to get their blog.
Hi. For different reasons, I have the exact same question. I want to programatically create user accouts (and blogs for the user too actually). andrea_r's answer didn't really answer the question.
The only way I can think of is to connect to the mysql database and actually create the account but that sounds like a pain in the butt. Does anyone have any suggestions?
No, your question is different. The OP wanted the users in there first, and then a blog created after they paid.
When a user signs up in MU, they can have a blog right off the bat when they create their username.
Do you have a list of users you're trying to add in and want a blog created for each of them automatically?
Hi,
I have a similar situation. I want to use a PHP script to create a new username and blog. What are the best API functions to use for this? Thanks!
If you take a look in /wp-includes/wpmu-functions.php all the necessary functions are in there. I guess you would be interested in wpmu_create_user() and wpmu_create_blog().
Cheers,
Steve