diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2017-04-11 11:41:55 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-11 11:41:55 +0200 |
commit | 5ca5ebe584999d6dbc4b363bb285c8ae00c1b5f2 (patch) | |
tree | de54b38f1f47336def729278c39fa86bd24243e1 /core/templates | |
parent | 1846e1262d1cd1dea6895c45ca13608acf3fbf11 (diff) | |
parent | b15c11b93be53d5fd5cfcee9b387b8744d08cff4 (diff) | |
download | nextcloud-server-5ca5ebe584999d6dbc4b363bb285c8ae00c1b5f2.tar.gz nextcloud-server-5ca5ebe584999d6dbc4b363bb285c8ae00c1b5f2.zip |
Merge pull request #2618 from nextcloud/2fa-challenge-text
Move log out and backup codes link into 2fa box for better readability
Diffstat (limited to 'core/templates')
-rw-r--r-- | core/templates/twofactorselectchallenge.php | 20 | ||||
-rw-r--r-- | core/templates/twofactorshowchallenge.php | 26 |
2 files changed, 25 insertions, 21 deletions
diff --git a/core/templates/twofactorselectchallenge.php b/core/templates/twofactorselectchallenge.php index 5cfba8bcb47..431f4c78c22 100644 --- a/core/templates/twofactorselectchallenge.php +++ b/core/templates/twofactorselectchallenge.php @@ -18,13 +18,15 @@ <?php endforeach; ?> </ul> </p> + <p class="two-factor-link"> + <a class="button" <?php print_unescaped($_['logout_attribute']); ?>><?php p($l->t('Cancel log in')) ?></a> + <?php if (!is_null($_['backupProvider'])): ?> + <a class="button" href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('core.TwoFactorChallenge.showChallenge', + [ + 'challengeProviderId' => $_['backupProvider']->getId(), + 'redirect_url' => $_['redirect_url'], + ] + )) ?>"><?php p($l->t('Use backup code')) ?></a> + <?php endif; ?> + </p> </div> -<a class="two-factor-link" <?php print_unescaped($_['logout_attribute']); ?>><?php p($l->t('Cancel log in')) ?></a> -<?php if (!is_null($_['backupProvider'])): ?> -<a class="two-factor-link" href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('core.TwoFactorChallenge.showChallenge', - [ - 'challengeProviderId' => $_['backupProvider']->getId(), - 'redirect_url' => $_['redirect_url'], - ] - )) ?>"><?php p($l->t('Use backup code')) ?></a> -<?php endif; diff --git a/core/templates/twofactorshowchallenge.php b/core/templates/twofactorshowchallenge.php index 4f3741b5dfe..ec760ead7c7 100644 --- a/core/templates/twofactorshowchallenge.php +++ b/core/templates/twofactorshowchallenge.php @@ -12,22 +12,24 @@ $template = $_['template']; ?> <div class="warning"> - <h2 class="two-factor-header"><?php p($provider->getDisplayName()); ?></h2> - <?php if ($error): ?> + <h2 class="two-factor-header"><?php p($provider->getDisplayName()); ?></h2> + <?php if ($error): ?> <?php if($error_message): ?> <p><strong><?php p($error_message); ?></strong></p> <?php else: ?> <p><strong><?php p($l->t('Error while validating your second factor')); ?></strong></p> <?php endif; ?> + <?php endif; ?> + <?php print_unescaped($template); ?> + <p class="two-factor-link"> + <a class="button" <?php print_unescaped($_['logout_attribute']); ?>><?php p($l->t('Cancel log in')) ?></a> + <?php if (!is_null($_['backupProvider'])): ?> + <a class="button" href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('core.TwoFactorChallenge.showChallenge', + [ + 'challengeProviderId' => $_['backupProvider']->getId(), + 'redirect_url' => $_['redirect_url'], + ] + )) ?>"><?php p($l->t('Use backup code')) ?></a> <?php endif; ?> - <?php print_unescaped($template); ?> + </p> </div> -<a class="two-factor-link" <?php print_unescaped($_['logout_attribute']); ?>><?php p($l->t('Cancel log in')) ?></a> -<?php if (!is_null($_['backupProvider'])): ?> -<a class="two-factor-link" href="<?php p(\OC::$server->getURLGenerator()->linkToRoute('core.TwoFactorChallenge.showChallenge', - [ - 'challengeProviderId' => $_['backupProvider']->getId(), - 'redirect_url' => $_['redirect_url'], - ] - )) ?>"><?php p($l->t('Use backup code')) ?></a> -<?php endif; |