What's new
Xen Factory

Register today to become a member! Once signed in, you'll be able to start purchasing our products, ask questions, request support and suggest new ideas!

  • This area is dedicated to the support of our xF1 add-ons. For xF2, please use the dedicated area: HERE.
  • We are aware that a no permission error was shown when you tried to purchase in the last 2 days, this is now fixed.

Suggestion Implemented Putting register button on tournament listing


New Member
I'm trying to put the register button on the tournament listing page like this:

But the problem is, only the "Unregister" button shows. I can't get the register button to show.

Here is the modification I did.

<li class="tournamentListItem" id="tournament-{$tournament.tournament_id}">
    <div class="listBlock main">
        <div class="listBlockInner">   
            <h3 class="title">
                <a href="{xen:link tournaments, $tournament}">
                <xen:if is="!{$tournament.bracket} AND ({$tournament.isRegistered} OR {$canRegisterTournament})">
            <div class="section {xen:string strtolower, $visitorLanguage.text_direction}" id="xfa_tourn_register">
                <div class="callToAction" style="display:inline-block; float: right;">
                    <div style="text-align: center;">
                    <xen:if is="!{$tournament.isRegistered}">
                        <a href="{xen:link tournaments/register, $tournament}">{xen:phrase xfa_tourn_register_now}</a>
                    <xen:else />
                            <a href="{xen:link tournaments/unregister, $tournament}">{xen:phrase xfa_tourn_unregister}</a>
            <div class="tournamentDetails muted"><xen:username user="{$tournament}" />,
                <a href="{xen:link tournaments, $tournament}" class="faint"><xen:datetime time="{$tournament.creation_date}" /></a><xen:comment>
                </xen:comment><xen:if is="{$showCategoryTitle}">, <a href="{xen:link tournaments/categories, $tournament}">{$tournament.category_title}</a></xen:if>
    <div class="listBlock tournamentStats">
        <div class="listBlockInner">
            <div class="pairsJustified">
                <xen:if is="{$tournament.winner_id}">
                    <dl class="tournamentWinner"><dt>{xen:phrase xfa_tourn_winner}:</dt> <dd><xen:username user="$tournament.winner" rich="true" /></dd></dl>
                <xen:else />
                <dl class="tournamentEnd">
                        <dt>{xen:phrase xfa_tourn_end_registering}:</dt>
                            <xen:if is="{$tournament.endRegistration}">
                                {xen:phrase xfa_tourn_closed}
                            <xen:elseif is="{$tournament.end_date}" />
                                <xen:datetime time="{$tournament.end_date}" />       
                            <xen:else />
                                {xen:phrase xfa_tourn_no_milestone}                     
                <dl class="tournamentSlots"><dt>{xen:phrase xfa_tourn_slots}:</dt> <dd>{$tournament.user_count}/{$tournament.slots}</dl>
                <dl class="tournamentUpdated"><dt>{xen:phrase xfa_tourn_updated}:</dt> <dd><xen:datetime time="{$tournament.last_update}" /></dd></dl>

Do you know how to get the register button to show? Thanks!


Freaky Coder
Staff member

It's because on the index, the registered status is not retrieved by the php code.

Can move that to feature request if you want.