wpseek.com
Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren



wp_update_blog_public_option_on_site_update › WordPress Function

Seit5.1.0
Veraltetn/v
wp_update_blog_public_option_on_site_update ( $site_id, $is_public )
Parameter: (2)
  • (int) $site_id Site ID.
    Erforderlich: Ja
  • (string) $is_public Whether the site is public. A numeric string, for compatibility reasons. Accepts '1' or '0'.
    Erforderlich: Ja
Definiert in:
Codex:

Updates the `blog_public` option for a given site ID.



Quellcode

function wp_update_blog_public_option_on_site_update( $site_id, $is_public ) {

	// Bail if the site's database tables do not exist (yet).
	if ( ! wp_is_site_initialized( $site_id ) ) {
		return;
	}

	update_blog_option( $site_id, 'blog_public', $is_public );
}