Classes | |
| class | Pluf_Date |
Functions | |
| Pluf_Date_Compare ($date1, $date2=null) | |
| Pluf_Date_Easy ($date, $ref=null, $blocks=2, $notime='now', $show=true) | |
| Pluf_Date_Compare | ( | $ | date1, | |
| $ | date2 = null | |||
| ) |
Set of functions to manage dates. Compare two date and returns the number of seconds between the first and the second. If only the date is given without time, the end of the day is used (23:59:59).
| string | Date to compare for ex: '2006-09-17 18:42:00' | |
| string | Second date to compare if null use now (null) |
| Pluf_Date_Easy | ( | $ | date, | |
| $ | ref = null, |
|||
| $ | blocks = 2, |
|||
| $ | notime = 'now', |
|||
| $ | show = true | |||
| ) |
Display a date in the format: X days Y hours ago X hours Y minutes ago X hours Y minutes left
"resolution" is year, month, day, hour, minute.
If not time is given, only the day, the end of the day is used: 23:59:59.
| string | Date to compare with ex: '2006-09-17 18:42:00' | |
| string | Reference date to compare with by default now (null) | |
| int | Maximum number of elements to show (2) | |
| string | If no delay between the two dates display ('now') | |
| bool | Show ago/left suffix |