diff options
-rw-r--r-- | include/nav.php | 23 | ||||
-rwxr-xr-x | view/tpl/navbar_default.tpl | 16 | ||||
-rwxr-xr-x | view/tpl/navbar_tucson.tpl | 16 |
3 files changed, 44 insertions, 11 deletions
diff --git a/include/nav.php b/include/nav.php index 6fd7d527b..89947e270 100644 --- a/include/nav.php +++ b/include/nav.php @@ -148,15 +148,20 @@ EOT; } else { if(! get_account_id()) { - $nav['login'] = login(true,'main-login',false,false); - $nav['loginmenu'][] = ['login',t('Login'),'',t('Sign in'),'login_nav_btn']; - App::$page['content'] .= replace_macros(get_markup_template('nav_login.tpl'), - [ - '$nav' => $nav, - 'userinfo' => $userinfo - ] - ); - + if(App::$module === 'channel') { + $nav['login'] = login(true,'main-login',false,false); + $nav['loginmenu'][] = ['login',t('Login'),'',t('Sign in'),'']; + } + else { + $nav['login'] = login(true,'main-login',false,false); + $nav['loginmenu'][] = ['login',t('Login'),'',t('Sign in'),'login_nav_btn']; + App::$page['content'] .= replace_macros(get_markup_template('nav_login.tpl'), + [ + '$nav' => $nav, + 'userinfo' => $userinfo + ] + ); + } } else $nav['alogout'] = ['logout',t('Logout'), "", t('End this session'),'logout_nav_btn']; diff --git a/view/tpl/navbar_default.tpl b/view/tpl/navbar_default.tpl index a3f61cd30..6e8463f46 100755 --- a/view/tpl/navbar_default.tpl +++ b/view/tpl/navbar_default.tpl @@ -1,8 +1,14 @@ {{if $nav.login && !$userinfo}} <div class="d-xl-none pt-1 pb-1"> + {{if $nav.loginmenu.1.4}} <a class="btn btn-primary btn-sm text-white" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}_collapse" data-toggle="modal" data-target="#nav-login"> {{$nav.loginmenu.1.1}} </a> + {{else}} + <a class="btn btn-primary btn-sm text-white" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} {{if $nav.register}} <a class="btn btn-warning btn-sm text-dark" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}" > {{$nav.register.1}} @@ -79,7 +85,15 @@ <ul class="navbar-nav mr-auto"> {{if $nav.login && !$userinfo}} <li class="nav-item d-none d-xl-flex"> - <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login">{{$nav.loginmenu.1.1}}</a> + {{if $nav.loginmenu.1.4}} + <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login"> + {{$nav.loginmenu.1.1}} + </a> + {{else}} + <a class="nav-link" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} </li> {{/if}} {{if $nav.register}} diff --git a/view/tpl/navbar_tucson.tpl b/view/tpl/navbar_tucson.tpl index acbe75876..602e0b988 100755 --- a/view/tpl/navbar_tucson.tpl +++ b/view/tpl/navbar_tucson.tpl @@ -1,8 +1,14 @@ {{if $nav.login && !$userinfo}} <div class="d-xl-none pt-1 pb-1"> + {{if $nav.loginmenu.1.4}} <a class="btn btn-primary btn-sm text-white" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}_collapse" data-toggle="modal" data-target="#nav-login"> {{$nav.loginmenu.1.1}} </a> + {{else}} + <a class="btn btn-primary btn-sm text-white" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} {{if $nav.register}} <a class="btn btn-warning btn-sm text-dark" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}" > {{$nav.register.1}} @@ -178,7 +184,15 @@ {{if $nav.login && !$userinfo}} <li class="nav-item d-none d-xl-flex"> - <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login">{{$nav.loginmenu.1.1}}</a> + {{if $nav.loginmenu.1.4}} + <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login"> + {{$nav.loginmenu.1.1}} + </a> + {{else}} + <a class="nav-link" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} </li> {{/if}} {{if $nav.register}} |