insert_blog


insert_blog ( $domain, $path, $site_id )

Parameters:
  • (string) domain The domain of the new site.
  • (string) path The path of the new site.
  • (int) site_id Unless you're running a multi-network install, be sure to set this value to 1.
See:
Returns:
  • (int|false) The ID of the new row
Defined at:
Change Log:
  • M: U

Description

Store basic site info in the blogs table.This function creates a row in the wp_blogs table and returns the new blog's ID. It is the first step in creating a new blog.

Related Functions

install_blog, add_user_to_blog, add_new_user_to_blog, insert_hooked_blocks, wp_insert_link

Top Google Results

User discussions

wpseek mobile