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

an error with my add-on

hello, I have a problem when adding a known my add-on function:
This add-on to create buttons at the top of the taigachat and I would allow a person to enter the id groups that can see the buttons, so I replaced the id groups my code with a style property:
<xen:if is="{xen:helper ismemberof, $visitor, @groupes_bouton_1}"><input type="submit" class="button primary" value="@titre_bouton_1" onclick="var bouton_1 = $('input#taigachat_message').val($('#taigachat_message').focus().val()+'@bouton_1');@option_bouton_1"></xen:if>
when I returned one id, it works perfectly, but when I returned two ids or more, there is only the first id returned that works, I've tried everything ..: (
Last edited:


Well-known member
If it is an input text field, it is most likely sent as a string back to the template. Is it a XenForo option? ALso, @groups_bouton_1 is not standard XF syntax.

Chris D

XenForo developer
Staff member
It's valid style property syntax, but you may want to try it's alternative:

{xen:helper ismemberof, $visitor, {xen:property groupes_bouton_1}}
Only other thing I can think of is:
{xen:helper ismemberof, $visitor, {xen:raw {xen:property groupes_bouton_1}}}
... but I don't think anything would be escaped here so raw output shouldn't make a difference.

If the contents of that field is a comma separated string, I'm pretty sure it should evaluate that correctly because:
{xen:helper ismemberof, $visitor, 1, 2, 3, 4}
... would be valid.


Well-known member
I wasn't actually thinking it was a style property. I don't actively add them for options of my add-ons. Didn't click.