Custom field value in template

There is a template viewHelper (see Core.php, inside the ViewHelper directory, for the syntac) that you can use to show the value in a template. :-)
 
There is a template viewHelper (see Core.php, inside the ViewHelper directory, for the syntac) that you can use to show the value in a template. :)

Thanks for that.

Do you know how I can pull a value from a specific field?
 
The userfieldvalue viewHelper asks for the field_id and the $user.

The syntax should be either this:
HTML:
{xen:helper userFieldValue, 'yourfieldid', $user}
or
HTML:
{xen:helper userFieldValue, yourfieldid, $user}

:)

XenForo uses this ViewHelper in the template "message_user_info".
 
The userfieldvalue viewHelper asks for the field_id and the $user.

The syntax should be either this:
HTML:
{xen:helper userFieldValue, 'yourfieldid', $user}
or
HTML:
{xen:helper userFieldValue, yourfieldid, $user}

:)

XenForo uses this ViewHelper in the template "message_user_info".

Can't seem to get this to work.

For example, I have this code in the template but I want to pull the value from the field to replace a space in the code.
 
I am really sorry, I replied without having a working XenForo installation to verify my instructions.

Maybe a developer can comment on this? From what I see, the above snippet should work. :)
 
Top Bottom