Ticket #16941: naturaltime-16941.diff

File naturaltime-16941.diff, 1.6 KB (added by antoviaque, 12 years ago)
  • docs/ref/contrib/humanize.txt

    diff --git a/docs/ref/contrib/humanize.txt b/docs/ref/contrib/humanize.txt
    index cdc3009..5797828 100644
    a b naturaltime  
    103103.. versionadded:: 1.4
    104104
    105105For datetime values, returns a string representing how many seconds,
    106 minutes or hours ago it was -- falling back to a longer date format if the
    107 value is more than a day old. In case the datetime value is in the future
    108 the return value will automatically use an appropriate phrase.
     106minutes or hours ago it was -- falling back to the :tfilter:`timesince`
     107format if the value is more than a day old. In case the datetime value is in
     108the future the return value will automatically use an appropriate phrase.
    109109
    110110Examples (when 'now' is 17 Feb 2007 16:30:00):
    111111
    Examples (when 'now' is 17 Feb 2007 16:30:00):  
    115115* ``17 Feb 2007 16:25:35`` becomes ``4 minutes ago``.
    116116* ``17 Feb 2007 15:30:29`` becomes ``an hour ago``.
    117117* ``17 Feb 2007 13:31:29`` becomes ``2 hours ago``.
    118 * ``16 Feb 2007 13:31:29`` becomes ``1 day ago``.
     118* ``16 Feb 2007 13:31:29`` becomes ``1 day, 3 hours ago``.
    119119* ``17 Feb 2007 16:30:30`` becomes ``29 seconds from now``.
    120120* ``17 Feb 2007 16:31:00`` becomes ``a minute from now``.
    121121* ``17 Feb 2007 16:34:35`` becomes ``4 minutes from now``.
    122122* ``17 Feb 2007 16:30:29`` becomes ``an hour from now``.
    123123* ``17 Feb 2007 18:31:29`` becomes ``2 hours from now``.
    124124* ``18 Feb 2007 16:31:29`` becomes ``1 day from now``.
     125* ``26 Feb 2007 18:31:29`` becomes ``1 week, 2 days from now``.
    125126
    126127.. templatefilter:: ordinal
    127128
Back to Top