WordPress.org

Ready to get started?Download WordPress

Codex

Function Reference/get post modified time

Contents

Description

Retrieve the time at which the post was last modified.

Note: One level »lower« than get_the_modified_time() (← link), but can take more arguments.

Usage

<?php get_post_modified_time$d$gmt$post$translate ); ?>

Parameters

$d
(string) (optional) Optional, default is 'U'. Either 'G', 'U', or php date format.
Default: U
$gmt
(boolean) (optional) Optional, default is false. Whether to return the gmt time.
Default: false
$post
(int|object) (optional) Optional, default is global post object. A post_id or post object
Default: null
$translate
(boolean) (optional) Optional, default is false. Whether to translate the result
Default: false

Return Values

(string) 
Returns timestamp

Change Log

Since: 2.0

Source File

get_post_modified_time() is located in wp-includes/general-template.php