header_authenticated.lp: add the hostname li only if it's greater than zero

Signed-off-by: XhmikosR <xhmikosr@gmail.com>
This commit is contained in:
XhmikosR
2025-06-02 17:10:47 +03:00
committed by GitHub
parent abd4d9d3b9
commit f78257bd8e

View File

@@ -54,12 +54,14 @@ mg.include('header.lp','r')
</button>
<div class="navbar-custom-menu">
<ul class="nav navbar-nav">
<li<? if string.len(hostname) == 0 then ?> class="hidden"<? end ?>>
<p class="navbar-text">
<span class="hidden-xs">hostname:</span>
<code><?=hostname?></code>
</p>
</li>
<? if string.len(hostname) > 0 then ?>
<li>
<p class="navbar-text">
<span class="hidden-xs">hostname:</span>
<code><?=hostname?></code>
</p>
</li>
<? end ?>
<li class="dropdown user user-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
<i class="fa fa-bars"></i>