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

As Designed Date format for "Joined" and "Birthday"

Discussion in 'Resolved Bug Reports' started by twollert, Jan 18, 2011.

  1. twollert

    twollert Active Member

    I chose the date format "d. F Y" in the ACP, so it should be e.g. "01. April 1970" (German format).

    If the user don't allow to see the age, the birthday is shown as "April 1" (instead of "01. April").
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Is that format supported by the PHP date function?
    I don't see it listed here: http://php.net/manual/en/function.date.php

    Edit: Ah yes, it's shown in the examples:
    $today = date("m.d.y");                         // 03.10.01
    Although interestingly, it lists "d" as 2 digits with leading zeros, which your example doesn't have.
    Have you tried using "j." ?
  3. twollert

    twollert Active Member

    "d. F Y" is working well in all other areas of the forum, e.g.:


    Only in the field "Birthday" (without the year!) the format isn't correct. So, I think it's a XenForo bug.

    Sorry, that was my mistake. I edited my original post.
  4. Kier

    Kier XenForo Developer Staff Member

    We actually hard-code the birthday format for the day-month only format, so strictly speaking this is working as designed.
  5. Walter

    Walter Well-Known Member

    Sorry, but this won't work in many parts of the world and in 2011 we call this a bug :)
    twollert likes this.
  6. Kier

    Kier XenForo Developer Staff Member

    What won't work? We return a localized version of date('F j'), so it will respond to translation - where's the serious limitation there?
  7. twollert

    twollert Active Member

    Can you explain this part, please? (Is there a phrase "F j" which I can change to "d. F"?)
  8. Mike

    Mike XenForo Developer Staff Member

    It's just the internal reference for "birthday" date types. You can explicitly override the type in the template, if it's that significant.

    Kier was trying to get more info on the underlying problem. While we could expose this as a format type, it's for one place in the entire application. We try to avoid that. It may not be ideal, but is the current format acceptable?
  9. twollert

    twollert Active Member

    OK, I will do that. Thanks! [​IMG]
  10. twollert

    twollert Active Member

    What exactly do I have to change in which template to set the birthday format to d. F (when there is no year)?

Share This Page