I'm running Joomla 2.5.1 for my website.
For the user registration, there's only Name, Username, Password, Confirm Password, Email Address, and Confirm Email Address.
I'm able to go to 'user-profile' and enable fields such as Address, Country, etc..
However, i want to add additional information such as Company Name, etc..
May i know how can this be done?
the problem is how to access to this profile data. this
JFactory::getUser()->get('address1','');
doesn't seem to work.
but this does the job:
jimport('joomla.user.helper');
$user = & JFactory::getUser();
$profile = JUserHelper::getProfile($user->id);
echo $profile->profile['address1'];
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With