1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.


Discussion in 'XenForo Development Discussions' started by Valhalla, May 31, 2014.

  1. Valhalla

    Valhalla Well-Known Member

    I'm trying to display a date and time in an absolute format (not relative) using a UNIX time value. For what reason might this expression not work in a template?

    <xen:date time="{$conversation.message_date}" />
    The {$conversation.message_date} value is a UNIX time stamp.

    I expected this to work, but I get an error upon saving the template.
  2. Chris D

    Chris D XenForo Developer Staff Member

    There are a few variations on xen syntax for date/time.

    This should work:
    {xen:datetime $conversation.message_date, absolute}
  3. Valhalla

    Valhalla Well-Known Member

    Works fine, thanks.
  4. Kintaro

    Kintaro Well-Known Member

Share This Page