How to hide the Login button?
Version 1.1 by Lucas Charpentier (Sereza7) on 2024/11/19
XWiki 16.10.0+ XWiki has a login button on the top navigation bar.
___
The register button can easily be removed by removing the guest user permission to Register.
The Log-in button needs a more specific action:
- Log in as an admin of your wiki
- Access the hidden page Registration. In order to toggle hidden page display, use x+x+x+h.
- Edit the objects of the Registration page. In order to have the UI button to edit page objects, make sure you're an advanced user with x+x+x+a.
- Update the content of the XWiki.UIExtensionClass object you can find on Registration:
- Remove lines 11 to 15, containing the HTML definition of the anchor:
#if ($xcontext.user == 'XWiki.XWikiGuest' && !$xcontext.inactiveUserReference)
<li>
<a href="$xwiki.getURL('XWiki.XWikiLogin', 'login', "xredirect=$redirectURL&loginLink=1")" id="tmLogin" rel="nofollow">$escapetool.xml($services.localization.render('login'))</a>
</li>
#end
- Save your changes.
From then on, the login button in the navbar will not be shown anymore on your wiki.