How to change shown icon in messages?


Hello, I have added below line to my message template to show my custom user field!
its working fine, but now I would like to change the img file to something different than what is set in custom user field for "Youtube" for this only

Are there anyway that I can change the img for this?

{xen:helper userFieldValue, $userFieldsInfo.Youtube, $message, {$message.customFields.Youtube}}

Jake Bunce

XenForo moderator
Staff member
Rather than using {xen:helper userFieldValue...} which will use the display HTML from the custom field, you can just insert your own HTML with appropriate variables. Example:

<img src="path/to/images/{$message.customFields.Youtube}.gif" />
This example uses the value of the custom field as part of the image path.