WP_MS_Sites_List_Table::column_lastupdated() WordPress Method

The WP_MS_Sites_List_Table::column_lastupdated() method is used to display the last updated date for a site in the WordPress multisite network. This is useful for keeping track of when a site was last updated and for knowing if a site is up-to-date.

WP_MS_Sites_List_Table::column_lastupdated( array $blog ) #

Handles the lastupdated column output.


Parameters

$blog

(array)(Required)Current site.


Top ↑

Source

File: wp-admin/includes/class-wp-ms-sites-list-table.php

	public function column_lastupdated( $blog ) {
		global $mode;

		if ( 'list' === $mode ) {
			$date = __( 'Y/m/d' );
		} else {
			$date = __( 'Y/m/d g:i:s a' );
		}

		echo ( '0000-00-00 00:00:00' === $blog['last_updated'] ) ? __( 'Never' ) : mysql2date( $date, $blog['last_updated'] );
	}


Top ↑

Changelog

Changelog
VersionDescription
4.3.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.