pike.git / lib / modules / Calendar.pmod / FAQ

version» Context lines:

pike.git/lib/modules/Calendar.pmod/FAQ:138:    > Calendar.now()->format_nicez();    Result: "10 Jan 10:51:15.489603 CET"       or in a format not depending on the unit,       > Calendar.Week()->format_ymd();    Result: "2001-01-08"    > Calendar.Day()->format_time();    Result: "2001-01-10 00:00:00"    -  This is all the formats: +  These are all the formats:    -  +  format_commonlog "10/Jan/2001:10:49:57 +0100"    format_ext_time "Wednesday, 10 January 2001 10:49:57"    format_ext_time_short "Wed, 10 Jan 2001 10:49:57 CET"    format_ext_ymd "Wednesday, 10 January 2001"    format_iso_time "2001-01-10 (Jan) -W02-3 (Wed) 10:49:57 UTC+1"    format_iso_ymd "2001-01-10 (Jan) -W02-3 (Wed)" -  +  format_iso_short "20010110T10:49:57"    format_mod "10:49"    format_month "2001-01"    format_month_short "200101"    format_mtime "2001-01-10 10:49" -  +  format_nice "10 Jan 2001 10:49:57" +  format_nicez "10 Jan 2001 10:49:57 CET"    format_time "2001-01-10 10:49:57"    format_time_short "20010110 10:49:57"    format_time_xshort "010110 10:49:57"    format_tod "10:49:57"    format_tod_short "104957"    format_todz "10:49:57 CET"    format_todz_iso "10:49:57 UTC+1"    format_week "2001-w2"    format_week_short "2001w2"    format_iso_week "2001-W02"
pike.git/lib/modules/Calendar.pmod/FAQ:170:    format_xtime "2001-01-10 10:49:57.539198"    format_xtod "10:49:57.539658"    format_ymd "2001-01-10"    format_ymd_short "20010110"    format_ymd_xshort "010110"       format_ctime "Wed Jan 10 10:49:57 2001\n"    format_smtp "Wed, 10 Jan 2001 10:49:57 +0100"    format_http "Wed, 10 Jan 2001 09:49:57 GMT"    +  For objects with a size, e.g. when taking the distance between two +  time points, the format_elapsed function can also be called to get +  something similar to "35d8:06:41.547". +    -------------------------------------------------------------------------      Q: How old am I?      A: First, you need to create the time period representing your age.       > object t=Calendar.dwim_time("1638 dec 23 7:02 pm")    ->distance(Calendar.now());    Result: Fraction(Thu 23 Dec 1638 19:02:00.000000 LMT -    Wed 10 Jan 2001 10:53:33.032856 CET)