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

XF 1.5 Adding tab to user_edit Admin template

#1
What's the recommended way to add a tab to the Admin template "user_edit"? I see that there are "slots" like
Code:
<!-- slot: pre_preferences -->
...except I can't do a replacement on those because they each occur twice, once in the tab list and once where the corresponding tab pane is defined. I would need to put something different in each place, and I don't even think I can use a PHP callback for this as the replacement function only receives the matches as an argument, not the original template text.
 

Mike

XenForo developer
Staff member
#2
You should use the slots, though it's not ideal that they're the same thing. Unfortunately, it won't be changed in 1.x at this point.

Realistically, you can match a little extra after the slot to make the match unique. (You would insert your value before what you matched then.)