insert_blog()
insert_blog( string $domain, string $path, int $site_id )
将基本站点信息存储在blogs表中。
Store basic site info in the blogs table.
说明(Description)
另见函数 wp_insert_site()
参数(Parameters)
参数 | 类型 | 必填 | 说明 |
---|---|---|---|
$domain | (string) | 必需 | 新站点的域。 |
$path | (string) | 必需 | 新站点的路径。 |
$site_id | (int) | 必需 | 除非正在运行多网络安装,否则请确保将此值设置为1。 |
返回(Return)
(int|false)新行的ID
源码(Source)
更新版本 | 源码位置 | 使用 | 被使用 |
---|---|---|---|
5.1.0 | wp-includes/ms-deprecated.php:570 | 1 function | 4 |
insert_blog() 为WP2原创文章,链接:https://www.wp2.cn/functions/insert_blog/