--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-general+unsub...@googlegroups.com.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
Visit this group at https://groups.google.com/group/joomla-dev-general.
For more options, visit https://groups.google.com/d/optout.
Do something like:JDispatcher::getInstance()->trigger('onContentPrepare', array ('com_users.user', &JFactory::getUser(), new JRegistry(), 0));print_r(JFactory::getUser()->jcfields);
On Wed, May 3, 2017 at 4:55 PM, Tigran Sargsyan <tigran.sar...@gmail.com> wrote:
суббота, 8 апреля 2017 г., 11:48:08 UTC+3 пользователь James Newton написал:
> I've created a new custom user field (Joomla! 3.7.0-rc1). Its a media field holding named "logo" allowing users to upload a logo image.
> I'm attempting to use that image elsewhere in the template and thought that I would be able to use ...
>
> <?php
> $user = JFactory::getUser();
> echo $user->logo;
> ?>
>
> ...to access the new custom user field (named logo). I haven't been able to find any documentation yet on how we'll be able to access these custom fields in templates or other extensions once we've created them in the backend. Any help would be greatly appreciated.
0
down vote
JLoader::register('FieldsHelper', JPATH_ADMINISTRATOR . '/components/com_fields/helpers/fields.php');
print_r( FieldsHelper::getFields('com_users.user', ['id'=> JFactory::getUser()->id]));
--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-general+unsub...@googlegroups.com.
To post to this group, send an email to joomla-de...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-general+unsub...@googlegroups.com.
To post to this group, send email to joomla-dev-general@googlegroups.com.