_update_blog_date_on_post_publish

Advertisement

Summery Summery

Handler for updating the site’s last updated date when a post is published or an already published post is changed.

Syntax Syntax

_update_blog_date_on_post_publish( string $new_status, string $old_status, WP_Post $post )

Parameters Parameters

$new_status

(Required) The new post status.

$old_status

(Required) The old post status.

$post

(Required) Post object.

Source Source

File: wp-includes/ms-blogs.php

	global $wpdb;

	if ( ! empty( $deprecated ) ) {
		_deprecated_argument( __FUNCTION__, 'MU' ); // Never used.
	}

	return $wpdb->get_results( $wpdb->prepare( "SELECT blog_id, domain, path FROM $wpdb->blogs WHERE site_id = %d AND public = '1' AND archived = '0' AND mature = '0' AND spam = '0' AND deleted = '0' AND last_updated != '0000-00-00 00:00:00' ORDER BY last_updated DESC limit %d, %d", get_current_network_id(), $start, $quantity ), ARRAY_A );
}

/**
 * Handler for updating the site's last updated date when a post is published or
 * an already published post is changed.
 *
 * @since 3.3.0

Advertisement

Changelog Changelog

Changelog
Version Description
3.3.0 Introduced.

Advertisement

Leave a Reply