Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




get_post_modified_time [ WordPress Function ]

get_post_modified_time ( $d = 'U', $gmt = false, $post = null, $translate = false )
Parameters:
  • (string) $d Optional, default is 'U'. Either 'G', 'U', or php date format.
  • (bool) $gmt Optional, default is false. Whether to return the gmt time.
  • (int|object) $post Optional, default is global post object. A post_id or post object
  • (bool) $translate Optional, default is false. Whether to translate the result
Returns:
  • (string) Returns timestamp
Defined at:



Retrieve the time at which the post was last modified.

Source


<?php
function get_post_modified_time$d 'U'$gmt false$post null$translate false ) {
    
$post get_post($post);

    if ( 
$gmt )
        
$time $post->post_modified_gmt;
    else
        
$time $post->post_modified;
    
$time mysql2date($d$time$translate);

    return 
apply_filters('get_post_modified_time'$time$d$gmt);
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

Gebruikersdiscussies [ wordpress.org ]

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics