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

XF 1.4 Displaying age - a nightmare..

Discussion in 'XenForo Questions and Support' started by Glockie, Mar 12, 2015.

  1. Glockie

    Glockie Well-Known Member

    My forums are very dependent on user ages.
    As such, I am having a nightmare getting year of birth - displayed, while omitting the actual date of birth!

    My users certainly don't wish to display their full dob, but definitely do want to display year of birth.
    We have both options; display month and day and then display year.

    I untick display day and month, for obvious privacy, but then the year disappears...
    This is something I can't really do without as it is an absolute must.!

    Can anyone tell me what I am doing wrong and if there is set order or something for this?
    Or a magic button etc ;)
    Many thanks
  2. Brogan

    Brogan XenForo Moderator Staff Member

    So you want to to display the year of birth only and not the day or month?

    That would require customisation.
  3. Glockie

    Glockie Well-Known Member

    It's an option within the ACP!?
    Even under default?.....
    Am I missing something?

  4. Brogan

    Brogan XenForo Moderator Staff Member


    You can show day and month or day, month and year.

    You can't show just the year.
    Amaury likes this.
  5. Glockie

    Glockie Well-Known Member

    But the options are there to allow, year of birth but not day and month...
    Surely it's safe to say that people won't mind showing they are, say 38, but not 1st of January 1977?
    If the options are available as administrators, why don't they function?
    Or, is it a bug or redundant?

    Seems very odd that we have the options to display year, and month /day - but they don't actually display. Unless you wish the full DOB to be shown, which is obviously not advisable.
  6. Despair

    Despair Active Member

    Glockie likes this.
  7. Brogan

    Brogan XenForo Moderator Staff Member

    Strictly speaking, the ACP option for year of birth should be a disabled checkbox dependent on the day and month of birth.
  8. Glockie

    Glockie Well-Known Member

    Absolutely spot on. This is a serious(ish) kind of issue for me. As my users are heavily based upon age, due to all sorts of things.
    So, displaying year of birth - you know, age, is important..
    DOB is absurd to display.

    So the bug is closed and any further developments or is it a case of, that's it?
    Thanks for the reply and link. Appreciated :)
  9. Glockie

    Glockie Well-Known Member

    The last 3 or 4 replies in that thread, is exactly what's happening to us right now... @Despair :rolleyes:o_O
  10. Despair

    Despair Active Member

    Most likely if anything is changed it will just be the ACP updated like mentioned above. :( You'd probably have to make a separate suggestion for what you require (if one was not already made).
  11. Glockie

    Glockie Well-Known Member

    Or, as suggested, pay for custom development - just to display year of birth without revealing the full DOB - when the options exist.... wow...
    Another £50-250 addon en-route then!
  12. Liam W

    Liam W Well-Known Member

    Depends who you hire...
  13. Glockie

    Glockie Well-Known Member

    Hi Liam, well you do development.. Is this something you can do?
  14. Liam W

    Liam W Well-Known Member

    Start a conversation with me :)
  15. sbj

    sbj Well-Known Member

    I solved this issue with Custom User Fields.

    First, delete in register_form and in user profile the date of birth fields.

    Then create a custom user field (dropdownbox) and manually add 116 choices: 1900 - 2015.

    Then make the custom user field required and people will be able to choose birth of year instead the full date. So everything stays anonymous but still the year of birth will be displayed in user profiles.
    Last edited: Mar 13, 2015
    Glockie likes this.
  16. rainmotorsports

    rainmotorsports Well-Known Member

    If all it was dependent on is age, not sure why the age in post bit via a free addon by ChrisD isn't sufficient rather than the year.
  17. Tracy Perry

    Tracy Perry Well-Known Member

    Not exactly - from my looking at the option, the display year is a sub-option of display day/month. If the day/month is not selected, then the sub-option is not available. If it was an equivalent option, it would not be stepped inward to the right but be on the same line as the tick for the day/month.
    Do I wish it worked the way you are asking about? Yes, I do, but I realized that it didn't and just hope that some day either it will be coded to have year only as an option, or just the age without any m/d/y display.
  18. Glockie

    Glockie Well-Known Member

    Yes I've installed this, and @Liam W helped with something extraordinary actually. So now, I / we have it exactly how we need it to be. (y)(y)

    @Tracy Perry i agree mate but also in the ACP - the option IS there, and that's what's thrown it out.
  19. Glockie

    Glockie Well-Known Member

    Very interesting to know! Thanks.
    I've a similar issue with gender fields, and have done pretty much the same thing.
    So have extended gender fields using this method.
    Never thought of doing it like this for age.
    Nice one. ;)

Share This Page