Support

  1. benjamin-st-george-botfield
  2. Support
  3. Tuesday, March 06 2018, 11:52 AM
  4.  Subscribe via email
Hi, I want to take user profile data and display it in a RS forms form.
I have done this for Name and e-mail using
//<code>
$user = JFactory::getUser();
return $user->get('email');
//</code>

I have tried this with the field names of my custom user fields, but it won't pull the user data back.

Can you advise on how I can make this work please.
Thank you.
admin Accepted Answer
Admin
  1. more than a month ago
  2. Support
  3. # 1
Hi thank you for your quick response.

I have tried that link and I have used several of the codes:
For example $user=JsnHelper::getUser(); echo $user->getField('school_name'); - I see this code in the text box, not the school name. I have tried it in a custom html module as well, it's the same.

I have also tried //<code>
$user=JsnHelper::getUser(); echo $user->getField('school_name');
//</code>
This just returns an empty field.


Is there an additional plugin I have to use?
Thanks.
  1. more than a month ago
  2. Support
  3. # 2
admin Accepted Answer
Admin
Hi,
I have tried that link and I have used several of the codes:
For example $user=JsnHelper::getUser(); echo $user->getField('school_name'); - I see this code in the text box, not the school name. I have tried it in a custom html module as well, it's the same.
I don't know how to works RSForm, anyway this is the correct PHP code like
$user = JFactory::getUser();
return $user->get('email');


I have also tried //<code>
$user=JsnHelper::getUser(); echo $user->getField('school_name');
//</code>
This just returns an empty field.
in this code missing the library
require_once(JPATH_SITE.'/components/com_jsn/helpers/helper.php');


I have tried it in a custom html module as well, it's the same.
Custom module can't parse PHP, it trigger only content plugin, if you need to load a value with content plugin then you need to see doc at http://docs.easy-profile.com/index.php/article/content-plugin
  1. more than a month ago
  2. Support
  3. # 3
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.

Request Support

Support is currently Offline

Support Availability

Working days: Monday to Friday. The support staff is not available on weekends; in the most of cases tickets will not be answered during that time.

Reply time: Depending on the complexity of your support issue it's usually between a few minutes and 24 hours for paid members and about one week for free members. When we expect longer delays we will notify you.

Guidelines

Before you post: read the documentation and search the forums for an answer to your question.

When you post: include Site Details if you request a support (you can use the form below the reply in Site Details tab).

Auto Solved Question: If after a week the author of the post does not reply to a request by moderator, the question will be marked as resolved.

Language: only English

Easy ProfileĀ® is not affiliated with or endorsed by Open Source Matters or the Joomla Project. Joomla is Free Software released under the GNU/GPL License.