1. REGISTRATION REQUIREMENTS:

    Register with your xenforo.com Username then start a conversation at xenforo.com w/Bob and provide the following:
    1. Your XenForo License Validation Token
    2. The Domain Name associated with the License
    NOTE: Your account will be validated once ALL requirements are verified/met. Thank you for your patience.

Custom Field (Date of Birth) - How to show Age?

Discussion in 'Showcase Support' started by tajhay, Jun 8, 2015.

  1. tajhay

    tajhay Active Member AMS Premium SC Premium Sportsbook Pickem Power Rankings Survivor

    Hi Bob,
    I have a custom field where i store a date format (dd/mm/yyyy). Lets imagine that being a date of birth field.

    Now is there a way i can show the age of that person based on current date? Wikipedia does this...just wondering if this is possible? If no, thats fine.
     
  2. Bob

    Bob Developer Staff Member

    It would have to be handled with PHP (its not something that can be done via template syntax or template display). It would also have to be custom as you'd need to edit one of the php files (a view file), check for the specific field_id (or id's), do some additional php to come up with the age and use a different view output to display the date and age.
     
    tajhay likes this.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.