Notice

The forum is in read only mode.

Support Forum

Welcome! Support Forums have been reactivated
Welcome the Technical Support section. Help us in assisting you by providing us with a concise and descriptive elaboration of your issues. Be specific and if possible, provide us with a step-by-step instruction in replicating your problem.

Member listing - more infos to add

7 years 5 months ago
  • Hermann's Avatar
    Topic Author
  • Hermann
  • Offline
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 0
Licenses:
JomSocial Active Socialize Expired

Thank you very much for your nice support!
Then I`ll wait for your snippet :-D

Have a nice weekend, Hermann

7 years 5 months ago
Licenses:

Hi, Hermann.

Here it is:

<?php $cuser = CFactory::getUser($row->user->id);
$birthDate = $cuser->getInfo('FIELD_BIRTHDATE');
$yearOnly = date("Y", strtotime($birthDate));
echo $yearOnly;
?>

You don't have to declare $cuser = CFactory::getUser($row->user->id); if you already did that.
Code displays year only from field FIELD_BIRTHDATE.
You may change field name to different one but field needs to use calendar/birthdate.


- Instead of saying: 'it's not working', explain the problem in detail.
- Screenshots with the URL visible in them and the problem marked are more than welcome.
- Tell us how to replicate the problem, we can't fix it if we can't find it.
- Make sure that your site/server meets JomSocial System Requirements
- Make sure to setup JomSocial Cron Job
- Always provide us with access details to the backend and ftp. We need it to debug problems.
- If you have a similar problem, but a solution you found isn't working, open a new thread instead of 'merging' with an existing one.

- Use the "Thank You" feature on any post that helped you
The following user(s) said Thank You: Hermann
Moderators: Piotr Garasiński
Powered by Kunena Forum

Join 180,000 websites creating Amazing communities

JomSocial is the most complete, easy-to-use addon that turns Joomla CMS into a
full -fledged, social networking site

TRY NOW BUY NOW