Set Joomla_Fullname value for account

I'm having a challenge getting setFieldValue to work for JOOMLA_FULLNAME for an user account. Here is the code that I'm using to test if I can create the custom field entry.


require_once ( JPATH_BASE . 'administrator' . DS . 'components' . DS . 'com_easysocial' . DS . 'includes' . DS . 'easysocial.php' );
require_once ( JPATH_BASE . 'administrator' . DS . 'components' . DS . 'com_easysocial' . DS . 'includes' . DS . 'user' . DS . 'user.php' );
require_once ( JPATH_BASE . 'media' . DS . 'com_easysocial' . DS . 'apps' . DS . 'fields' . DS . 'user' . DS . 'joomla_fullname' . DS . 'joomla_fullname.php' );


$user_id = (int) '658';

$user = ES::user($user_id);
$name = new SocialFieldUserJoomla_FullnameObject($user, NULL);

$name->first = (string) 'Fran';
$name->middle = (string) 'Fred';
$name->last = (string) 'Froster';
$name->name = (string) 'Fran Fred Froster';
echo ( '<br>');
var_dump($name);
echo ( '<br><br>');
echo ( $name->toJson() );

$user->setFieldValue('JOOMLA_FULLNAME', $name->toJson() );


I was able to get the setFieldValue to work for all the single fields as well as the address field, but the joomla_fullname just won't let me set the custom field value.

I have the latest version of Joomla and EasySocial installed on Ubuntu 16.04.

Any help would be appreciated.
Dan

This section can only be seen by users with a valid subscription.
If you have a valid subscription, please login now

Support is
Offline

It is currently a weekend from where we are at. Some answers may already be available on our documentation

Rest assured that we will get back to your posts as soon as the week starts!

Your time
Stack Ideas time