register.phtml 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <div class="prompt">
  2. <h1><?= _t('gen.auth.registration') ?></h1>
  3. <form method="post" action="<?= _url('user', 'create') ?>">
  4. <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" />
  5. <div class="form-group">
  6. <label for="new_user_name"><?= _t('gen.auth.username') ?></label>
  7. <input id="new_user_name" name="new_user_name" type="text" size="16" required="required" autocomplete="off" pattern="<?= FreshRSS_user_Controller::USERNAME_PATTERN ?>" autocapitalize="off" />
  8. <p class="help"><?= _i('help') ?> <?= _t('gen.auth.username.format') ?></p>
  9. </div>
  10. <?php if ($this->show_email_field) { ?>
  11. <div class="form-group">
  12. <label for="new_user_email">
  13. <?= _t('gen.auth.email') ?>
  14. </label>
  15. <input id="new_user_email" name="new_user_email" type="email" required />
  16. </div>
  17. <?php } ?>
  18. <div class="form-group">
  19. <label for="new_user_passwordPlain"><?= _t('gen.auth.password') ?></label>
  20. <div class="stick">
  21. <input type="password" id="new_user_passwordPlain" name="new_user_passwordPlain" required="required" autocomplete="new-password" pattern=".{7,}" />
  22. <a class="btn toggle-password" data-toggle="new_user_passwordPlain"><?= _i('key') ?></a>
  23. </div>
  24. <noscript><b><?= _t('gen.js.should_be_activated') ?></b></noscript>
  25. <p class="help"><?= _i('help') ?> <?= _t('gen.auth.password.format') ?></p>
  26. </div>
  27. <?php if ($this->show_tos_checkbox) { ?>
  28. <div class="form-group">
  29. <label class="checkbox" for="accept-tos">
  30. <input type="checkbox" name="accept_tos" id="accept-tos" value="1" required />
  31. <?= _t('gen.auth.accept_tos', _url('index', 'tos')) ?>
  32. </label>
  33. </div>
  34. <?php } ?>
  35. <div class="form-group form-group-actions">
  36. <?php
  37. $redirect_url = urlencode(Minz_Url::display(
  38. array('c' => 'index', 'a' => 'index'),
  39. 'php', true
  40. ));
  41. ?>
  42. <input type="hidden" name="r" value="<?= $redirect_url ?>" />
  43. <button type="submit" class="btn btn-important"><?= _t('gen.action.create') ?></button>
  44. <a href="<?= _url('index', 'index') ?>"><?= _t('gen.action.cancel') ?></a>
  45. </div>
  46. </form>
  47. <p><a href="<?= _url('index', 'about') ?>"><?= _t('gen.freshrss.about') ?></a></p>
  48. </div>