FOSSology  4.4.0
Open Source License Compliance by Open Source Software
timer Class Reference
Collaboration diagram for timer:
Collaboration graph

Public Member Functions

 getStartTime ()
 

Static Public Member Functions

static TimeAgo ($timestamp)
 

Public Attributes

 $startTime
 

Detailed Description

timer

general class to determine the elapse time between two times in time() format.

Version
"$Id: $"

Created on Sep 19, 2008 timer

Determine the elapse time between two times in time() format.

Usage: $t = new timer();

To determine elase time: $timePhrase = $t->timeAgo($t->getStartTime);

Definition at line 30 of file timer.php.

Member Function Documentation

◆ TimeAgo()

static timer::TimeAgo (   $timestamp)
static

TimeAgo($timestamp)

Return the text of the elapsed time between the timestamp and 'now'.

Parameters
string$timestampin time() format.
Returns
string $text the elapsed time as a phrase up to decades ago. E.g. 30 seconds or 1 day 2 hours 30 seconds.

This routine was taken from the php web site.

Definition at line 54 of file timer.php.


The documentation for this class was generated from the following file: