]> source.dussan.org Git - nextcloud-server.git/commitdiff
Identify the login page explicitly by the page title 33281/head
authorChristopher Ng <chrng8@gmail.com>
Wed, 20 Jul 2022 23:55:50 +0000 (23:55 +0000)
committerChristopher Ng <chrng8@gmail.com>
Wed, 20 Jul 2022 23:55:50 +0000 (23:55 +0000)
Signed-off-by: Christopher Ng <chrng8@gmail.com>
core/Controller/LoginController.php
core/templates/layout.guest.php

index ff2cb641f88207501221e1681a5d03690f799ed1..3694e672977c0a855237b837197fd2c9c9ca41e0 100644 (file)
@@ -201,12 +201,16 @@ class LoginController extends Controller {
 
                $parameters = [
                        'alt_login' => OC_App::getAlternativeLogIns(),
+                       'pageTitle' => $this->l10n->t('Login'),
                ];
 
                $this->initialStateService->provideInitialState('core', 'countAlternativeLogins', count($parameters['alt_login']));
 
                return new TemplateResponse(
-                       $this->appName, 'login', $parameters, 'guest'
+                       $this->appName,
+                       'login',
+                       $parameters,
+                       TemplateResponse::RENDER_AS_GUEST,
                );
        }
 
index 980d9abb7c4268b2dcc30d662cd4cc3e91591384..432bc4e860188bdfda384fb7e0c23320a3bbadc8 100644 (file)
@@ -7,7 +7,10 @@
  data-requesttoken="<?php p($_['requesttoken']); ?>">
                <meta charset="utf-8">
                <title>
-               <?php p($theme->getTitle()); ?>
+                       <?php
+                               p(!empty($_['pageTitle']) ? $_['pageTitle'] . ' – ' : '');
+                               p($theme->getTitle());
+                       ?>
                </title>
                <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
                <?php if ($theme->getiTunesAppId() !== '') { ?>