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

XF 1.4 Duplicating member_list_item for XenStaff-like AddOn

Discussion in 'Styling and Customization Questions' started by CaptainMorgan, Nov 21, 2014.

  1. CaptainMorgan

    CaptainMorgan Active Member

    Following @Jake Bunce 's advice, I was able to get this working on the member_list_item template. I have two concerns.

    1) I created a duplicate of the member_list_item template so that my code would not interfere with other stock XF templates. Naturally, {$user.customFields.field_id} works only on the stock member_list_item template and not mine. How do I go about getting this to work on my duplicate template? My code gets from the cache XenForo_Model_User, but this appears to not be what I need, so I tried XenForo_Model_UserField. This almost worked (see #2), but I had unserialize it. Is there another model I should be using?

    2) The value displayed on the member_list_item template is the choice's number, not the value of the text. So, instead of ouputting: "Field: Value", it's outputting "Field: Value's id". It is a dropdown custom field with a number of choices to pick from. How do I get that value's id to show its text instead?

    EDIT::So it seems this was what I needed for #2 above. Any chance on getting assistance with #1? Thanks
  2. CaptainMorgan

    CaptainMorgan Active Member

    Nevermind. I got it to work. I was preparing the user cards incorrectly.

    Thanks for looking anyways.

Share This Page