human_time_diff
human_time_diff ( $from, $to = 0 )
Parameters:- (int) from Unix timestamp from which the difference begins.
- (int) to Optional. Unix timestamp to end the time difference. Default becomes time() if not set.
Returns:- (string) Human-readable time difference.
Defined at:Change Log: - Introduced in WordPress: 1.5.0
- Deprecated in WordPress: —
Description
Determines the difference between two timestamps.The difference is returned in a human-readable format such as "1 hour",
"5 minutes", "2 days".