1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Custom User Field check box w/image?

Discussion in 'Styling and Customization Questions' started by Mendo, Jun 29, 2012.

  1. Mendo

    Mendo Member

    I would like a check box to tick for a custom user field, instead of a text string. Then when activated it would display an image under the avatar. If it's not ticked then there would be no image. I have the image code ready but I can't figure out the check box part. Is this possible?
  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Create a new user field:

    Admin CP -> Users -> Custom User Fields

    To create the image you need to specify the HTML:

    General Options: Value Display HTML

    For example:

    <img src="path/to/{$value}.gif" alt="{$value}" />
    Also, there is this option you need to enable:

    General Options: Viewable in message user info

    In addition, make sure this is enabled in your style:

    Admin CP -> Appearance -> Style Properties -> Message Elements -> Show custom user fields

    Now when a user enters a value into that field it will show the image in their posts.
  3. Hristo Avramov

    Hristo Avramov Active Member

    If I want to use sprite image, what should I do then, thank you!
  4. Market1234

    Market1234 Member

    I applied this logic to the resource custom feild but it doesn't work. Is there anything else I need to apply or activate?

  5. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member


    Nothing shows at all? It should show up in the user info area on the left side of posts.

    If it's not working then it might be due to a style customization. Try reverting the message_user_info template in your style.
  6. Market1234

    Market1234 Member

    I only get {text} or {url}
  7. Coop1979

    Coop1979 Well-Known Member

    How can I not show the Field Title and only show the value?

Share This Page