WordPress/wp-includes
Felix Arntz 9e2e491f1f Multisite: Complete the new CRUD API for managing sites.
New functions `wp_insert_site( $data )`, `wp_update_site( $id, $data )` and `wp_delete_site( $id )` are introduced to manage site rows in the `wp_blogs` table, forming the new CRUD API together with the existing `get_site()` / `get_sites()`. The new API provides various benefits over the previously existing API, fixing several cache invalidation issues and being hook-driven so that normalization and validation of the passed data can be fully customized.

New hooks introduced as part of this are the actions `wp_insert_site`, `wp_update_site`, `wp_delete_site`, `wp_validate_site_data` and the filter `wp_normalize_site_data`.

At this point, `wp_insert_site()` does not handle setting up the site's database tables, and `wp_delete_site()` does not handle dropping the site's database tables, so the two can not yet be used directly as full replacements of `wpmu_create_blog()` and `wpmu_delete_blog()`. Managing the site's database tables will be added via hooks as part of the follow-up ticket #41333.

The existing functions `wpmu_create_blog()`, `update_blog_details()`, and `wpmu_delete_blog()` make use of the respective new counterpart and will be obsolete once #41333 has been completed.

Props flixos90, jeremyfelt, spacedmonkey.
Fixes #40364.

Built from https://develop.svn.wordpress.org/trunk@43548


git-svn-id: http://core.svn.wordpress.org/trunk@43377 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-08-01 13:06:26 +00:00
..
certificates
css
customize
fonts
ID3
images
IXR
js Toolbar: Fail gracefully when adding events to non-existent elements 2018-07-19 22:00:25 +00:00
pomo
random_compat
Requests
rest-api REST API: Ensure attachments created with WP_REST_Attachments_Controller::create_item() on Windows have a relative path. 2018-07-24 16:52:25 +00:00
SimplePie
Text
theme-compat
widgets
admin-bar.php Taxonomy: Introduce is_taxonomy_viewable(). 2018-07-03 10:29:28 +00:00
atomlib.php
author-template.php
bookmark-template.php Docs: Fix typo in _walk_bookmarks() DocBlock. 2018-05-27 08:36:23 +00:00
bookmark.php
cache.php
canonical.php
capabilities.php Docs: Update @since version to 4.9.8 for meta registration subtype handling. 2018-07-23 17:02:25 +00:00
category-template.php
category.php
class-feed.php
class-http.php
class-IXR.php
class-json.php Docs: Fix typo in Services_JSON DocBlocks. 2018-06-28 02:20:54 +00:00
class-oembed.php
class-phpass.php
class-phpmailer.php
class-pop3.php
class-requests.php
class-simplepie.php
class-smtp.php
class-snoopy.php
class-walker-category-dropdown.php
class-walker-category.php
class-walker-comment.php
class-walker-nav-menu.php
class-walker-page-dropdown.php
class-walker-page.php
class-wp-admin-bar.php
class-wp-ajax-response.php
class-wp-comment-query.php
class-wp-comment.php
class-wp-customize-control.php
class-wp-customize-manager.php Posts, Post Types: Introduce edit_post_{$post->post_type} hook. 2018-07-25 20:57:25 +00:00
class-wp-customize-nav-menus.php Customize: Do not attempt to count uncountable value. 2018-07-17 14:38:24 +00:00
class-wp-customize-panel.php
class-wp-customize-section.php
class-wp-customize-setting.php
class-wp-customize-widgets.php
class-wp-dependency.php
class-wp-editor.php Editor: Use apply_filters_deprecated() for some deprecated filters. 2018-07-17 07:38:24 +00:00
class-wp-embed.php
class-wp-error.php
class-wp-feed-cache-transient.php
class-wp-feed-cache.php
class-wp-hook.php
class-wp-http-cookie.php
class-wp-http-curl.php
class-wp-http-encoding.php
class-wp-http-ixr-client.php
class-wp-http-proxy.php
class-wp-http-requests-hooks.php
class-wp-http-requests-response.php
class-wp-http-response.php
class-wp-http-streams.php
class-wp-image-editor-gd.php
class-wp-image-editor-imagick.php
class-wp-image-editor.php
class-wp-list-util.php
class-wp-locale-switcher.php
class-wp-locale.php
class-wp-matchesmapregex.php
class-wp-meta-query.php
class-wp-metadata-lazyloader.php
class-wp-network-query.php
class-wp-network.php
class-wp-oembed-controller.php
class-wp-post-type.php
class-wp-post.php
class-wp-query.php
class-wp-rewrite.php
class-wp-role.php
class-wp-roles.php
class-wp-session-tokens.php
class-wp-simplepie-file.php
class-wp-simplepie-sanitize-kses.php
class-wp-site-query.php
class-wp-site.php
class-wp-tax-query.php
class-wp-taxonomy.php
class-wp-term-query.php Docs: Change @since entry for WP_Term_Query::populate_terms() added in [43049] to 4.9.8. 2018-07-17 16:25:26 +00:00
class-wp-term.php
class-wp-text-diff-renderer-inline.php
class-wp-text-diff-renderer-table.php
class-wp-theme.php
class-wp-user-meta-session-tokens.php
class-wp-user-query.php
class-wp-user.php Docs: Remove obsolete $wpdb global references in WP_User::__construct() and WP_User::for_blog(). 2018-06-28 02:23:02 +00:00
class-wp-walker.php
class-wp-widget-factory.php
class-wp-widget.php
class-wp-xmlrpc-server.php
class-wp.php
class.wp-dependencies.php
class.wp-scripts.php
class.wp-styles.php
comment-template.php Privacy: Revert [43525]. 2018-07-24 17:06:24 +00:00
comment.php Posts, Post Types: Introduce edit_post_{$post->post_type} hook. 2018-07-25 20:57:25 +00:00
compat.php
cron.php Cron: Add hooks and a function to allow hijacking cron implementation. 2018-07-27 02:23:25 +00:00
date.php
default-constants.php
default-filters.php
default-widgets.php
deprecated.php
embed-template.php
embed.php
feed-atom-comments.php
feed-atom.php
feed-rdf.php
feed-rss2-comments.php
feed-rss2.php
feed-rss.php
feed.php
formatting.php Emoji: Update Twemoji to version 11.0. 2018-06-28 02:42:55 +00:00
functions.php Streams: Return early from wp_is_stream() for paths that aren't streams. 2018-07-17 07:54:25 +00:00
functions.wp-scripts.php
functions.wp-styles.php
general-template.php Emoji: Update Twemoji to version 11.0. 2018-06-28 02:42:55 +00:00
http.php
kses.php
l10n.php
link-template.php Privacy: Use the actual Privacy Policy page title in get_the_privacy_policy_link(). 2018-07-18 11:50:25 +00:00
load.php
locale.php
media-template.php
media.php
meta.php Docs: Add $object_subtype param documentation for sanitize_meta(). 2018-07-23 17:14:26 +00:00
ms-blogs.php Multisite: Complete the new CRUD API for managing sites. 2018-08-01 13:06:26 +00:00
ms-default-constants.php
ms-default-filters.php Multisite: Complete the new CRUD API for managing sites. 2018-08-01 13:06:26 +00:00
ms-deprecated.php Multisite: Complete the new CRUD API for managing sites. 2018-08-01 13:06:26 +00:00
ms-files.php
ms-functions.php Multisite: Complete the new CRUD API for managing sites. 2018-08-01 13:06:26 +00:00
ms-load.php
ms-settings.php
nav-menu-template.php
nav-menu.php
option.php
pluggable-deprecated.php
pluggable.php Posts, Post Types: Use COOKIEPATH when clearing post password cookie, as that's the path it's created with. 2018-05-27 01:33:22 +00:00
plugin.php
post-formats.php
post-template.php
post-thumbnail-template.php
post.php Posts, Post Types: Introduce edit_post_{$post->post_type} hook. 2018-07-25 20:57:25 +00:00
query.php
registration-functions.php
registration.php
rest-api.php
revision.php
rewrite.php
rss-functions.php
rss.php
script-loader.php I18N: Remove unused MediaElement.js strings. 2018-06-28 02:29:24 +00:00
session.php
shortcodes.php Coding Standards: Fix code indent in unescape_invalid_shortcodes(). 2018-02-25 16:36:30 +00:00
spl-autoload-compat.php
taxonomy.php Docs: Update @since version to 4.9.8 for meta registration subtype handling. 2018-07-23 17:02:25 +00:00
template-loader.php
template.php
theme.php
update.php
user.php Privacy: Add $request to $email_data to make it available to all filters. 2018-07-17 13:53:25 +00:00
vars.php
version.php Multisite: Complete the new CRUD API for managing sites. 2018-08-01 13:06:26 +00:00
widgets.php
wlwmanifest.xml
wp-db.php
wp-diff.php