nextcloud/core/templates/login.php

62 lines
2.6 KiB
PHP
Raw Normal View History

<!--[if IE 8]><style>input[type="checkbox"]{padding:0;}</style><![endif]-->
<form method="post">
2013-01-14 23:30:28 +04:00
<fieldset>
<?php if (!empty($_['redirect_url'])) {
2013-02-28 01:55:39 +04:00
print_unescaped('<input type="hidden" name="redirect_url" value="' . OC_Util::sanitizeHTML($_['redirect_url']) . '" />');
2013-01-14 23:30:28 +04:00
} ?>
<ul>
<?php if (isset($_['invalidcookie']) && ($_['invalidcookie'])): ?>
<li class="errors">
2013-02-28 01:55:39 +04:00
<?php p($l->t('Automatic logon rejected!')); ?><br>
<small><?php p($l->t('If you did not change your password recently, your account may be compromised!')); ?></small>
2013-01-14 23:30:28 +04:00
<br>
2013-02-28 01:55:39 +04:00
<small><?php p($l->t('Please change your password to secure your account again.')); ?></small>
2013-01-14 23:30:28 +04:00
</li>
<?php endif; ?>
<?php if (isset($_['invalidpassword']) && ($_['invalidpassword'])): ?>
2013-02-28 01:55:39 +04:00
<a href="<?php print_unescaped(OC_Helper::linkToRoute('core_lostpassword_index')) ?>">
2013-01-14 23:30:28 +04:00
<li class="errors">
2013-02-28 01:55:39 +04:00
<?php p($l->t('Lost your password?')); ?>
2013-01-14 23:30:28 +04:00
</li>
</a>
<?php endif; ?>
</ul>
<p class="infield grouptop">
<input type="text" name="user" id="user" placeholder=""
2013-02-28 01:55:39 +04:00
value="<?php p($_['username']); ?>"<?php p($_['user_autofocus'] ? ' autofocus' : ''); ?>
2013-01-14 23:30:28 +04:00
autocomplete="on" required/>
2013-02-28 01:55:39 +04:00
<label for="user" class="infield"><?php p($l->t('Username')); ?></label>
<img class="svg" src="<?php print_unescaped(image_path('', 'actions/user.svg')); ?>" alt=""/>
2013-01-14 23:30:28 +04:00
</p>
2013-01-14 23:30:28 +04:00
<p class="infield groupbottom">
<input type="password" name="password" id="password" value="" data-typetoggle="#show" placeholder=""
2013-02-28 01:55:39 +04:00
required<?php p($_['user_autofocus'] ? '' : ' autofocus'); ?> />
<label for="password" class="infield"><?php p($l->t('Password')); ?></label>
<img class="svg" id="password-icon" src="<?php print_unescaped(image_path('', 'actions/password.svg')); ?>" alt=""/>
2013-01-25 13:52:10 +04:00
<input type="checkbox" id="show" name="show" />
<label for="show"></label>
2013-01-14 23:30:28 +04:00
</p>
<input type="checkbox" name="remember_login" value="1" id="remember_login"/><label
2013-02-28 01:55:39 +04:00
for="remember_login"><?php p($l->t('remember')); ?></label>
2013-01-14 23:30:28 +04:00
<input type="hidden" name="timezone-offset" id="timezone-offset"/>
2013-02-28 01:55:39 +04:00
<input type="submit" id="submit" class="login primary" value="<?php p($l->t('Log in')); ?>"/>
2013-01-14 23:30:28 +04:00
</fieldset>
2011-08-08 19:57:45 +04:00
</form>
<?php if (!empty($_['alt_login'])) { ?>
<form id="alternative-logins">
<fieldset>
2013-02-28 01:55:39 +04:00
<legend><?php p($l->t('Alternative Logins')) ?></legend>
<ul>
2013-02-06 21:19:26 +04:00
<?php foreach($_['alt_login'] as $login): ?>
2013-02-28 01:55:39 +04:00
<li><a class="button" href="<?php print_unescaped($login['href']); ?>" ><?php p($login['name']); ?></a></li>
2013-02-06 21:19:26 +04:00
<?php endforeach; ?>
</ul>
</fieldset>
</form>
<?php } ?>
<?php
OCP\Util::addscript('core', 'visitortimezone');