• Settings
    • Locale
    • Change the locale of the datepicker, schedule and client side validation messages.

      Language
      English
      English
      English
      French
      German
      German
      German
      Italian
      Korean
      Spanish
      Catalan
      Dutch
      Portuguese
      Portuguese
      Arabic
      Arabic
      Bulgarian
      Bangla
      Bosnian
      Czech
      Greek
      Estonian
      Persian
      Finnish
      Danish
      Hindi
      Indonesian
      Icelandic
      Croatian
      Japanese
      Hungarian
      Hebrew
      Georgian
      Central Kurdish
      Khmer
      Kyrgyz
      Kazakh
      Lithuanian
      Latvian
      Malay
      Norwegian
      Polish
      Romanian
      Russian
      Slovak
      Slovenian
      Serbian
      Serbian
      Swedish
      Thai
      Turkish
      Ukrainian
      Uzbek
      Vietnamese
      Chinese
      Chinese
  • Resources

TimeAgo Basic

TimeAgo generates automatically updating fuzzy timestamps (e.g. "4 minutes ago"). Based on jquery-timeago by Ryan McGeary.

TimeAgo Tag Documentation

TimeAgo displays relative time for a given date/time value.

NameTypeRequiredDefaultDescription
id String false generated Unique identifier of the component in a namingContainer.
rendered boolean false true Boolean value to specify the rendering of the component, when set to false component will not be rendered.
binding UIComponent false generated An EL expression referring to a server side UIComponent instance in a backing bean.
widgetVar String false generated ('widget_' + componentClientId) Name of the client side widget.
locale Object false Locale used to localize the relative time. Can be a string or java.util.Locale instance.
style String false Inline style of the component.
styleClass String false Style class of the component.
titlePattern String false Pattern used for the title text.
value Object true Date/time value to display.
Tag Documentation Widget Source Basic Localized
Basic Usage

Fuzzy timestamps for dates in the past and in the future. The titlePattern sets the tooltip with the exact date.

You've opened this page .

PrimeFaces Extensions was first released .

The next month is .

Usage


<div class="card">
    <h5>Basic Usage</h5>
    <p>Fuzzy timestamps for dates in the past and in the future. The <code>titlePattern</code> sets the tooltip with the exact date.</p>
    <p>
        You've opened this page
        <pe:timeAgo value="#{basicTimeAgoController.created}"
                    titlePattern="MMMM dd yyyy hh:mm a" style="font-weight:bold" />.
    </p>
    <p>
        PrimeFaces Extensions was first released
        <pe:timeAgo value="#{basicTimeAgoController.firstRelease}"
                    titlePattern="MMMM dd yyyy" style="font-weight:bold"/>.
    </p>
    <p>
        The next month is
        <pe:timeAgo value="#{basicTimeAgoController.nextMonth}"
                    titlePattern="MMMM dd yyyy" style="font-weight:bold"/>.
    </p>
</div>