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

xen:helper username for UserID

nrep

Well-known member
#1
I'm trying to get "xen:helper username" working when all I have is a UserID string (set as a xenoption in the admin panel).

This doesn't work, but is there a way around this?

Code:
{xen:helper username, {$xenOptions.customuserid}}
 

Chris D

XenForo developer
Staff member
#2
The <xen:username or {xen:helper username or {xen:username or whatever other variations of it, all require a user_id AND username to work.
 

nrep

Well-known member
#3
The <xen:username or {xen:helper username or {xen:username or whatever other variations of it, all require a user_id AND username to work.
Cheers Chris, I'll add another option field for that. What would be the most basic usage of that xen:helper with a userid and username variable?

Thanks for your help on XenForo - you've helped a lot of coding newbies like me! It is very much appreciated!
 

Chris D

XenForo developer
Staff member
#4
It would be something like:

{xen:helper username, {xen:array 'user_id={$xenOptions.customuserid}', 'username={$xenOptions.customusername}'}}

I haven't tested it... but that should work.