index.phtml 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. declare(strict_types=1);
  3. /** @var FreshRSS_View $this */
  4. $this->partial('aside_subscription');
  5. ?>
  6. <main class="post">
  7. <div class="link-back-wrapper">
  8. <a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a>
  9. </div>
  10. <h1><?= _t('sub.menu.label_management') ?></h1>
  11. <h2><?= _t('sub.title.add_label') ?></h2>
  12. <form id="add_tag" method="post" action="<?= _url('tag', 'add') ?>" autocomplete="off">
  13. <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" />
  14. <div class="form-group">
  15. <label class="group-name" for="new_label_name"><?= _t('sub.tag.name') ?></label>
  16. <div class="group-controls">
  17. <input id="new_label_name" name="name" type="text" autocomplete="off" required="required" />
  18. </div>
  19. </div>
  20. <div class="form-group form-actions">
  21. <div class="group-controls">
  22. <button type="submit" class="btn btn-important"><?= _t('gen.action.add') ?></button>
  23. </div>
  24. </div>
  25. </form>
  26. <?php if (count($this->tags) > 0): ?>
  27. <h2><?= _t('gen.action.manage') ?></h2>
  28. <ul>
  29. <?php foreach ($this->tags as $tag): ?>
  30. <li><a href="<?= _url('tag', 'update', 'id', $tag->id()) ?>"><?= $tag->name() ?></a></li>
  31. <?php endforeach; ?>
  32. </ul>
  33. <?php endif; ?>
  34. </main>