blob: bb11f9f695f0b467e1fd0b98d9cfb781fdfe8442 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
<?php /** @var FreshRSS_View $this */ ?>
<main class="post content">
<div class="link-back-wrapper">
<a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a>
</div>
<h1><?= _t('index.log') ?></h1>
<form method="post" action="<?= _url('index', 'logs') ?>"><p>
<input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" />
<input type="hidden" name="clearLogs" />
<button type="submit" class="btn"><?= _t('index.log.clear') ?></button>
</p></form>
<?php
/** @var array<FreshRSS_Log> $items */
$items = $this->logsPaginator->items();
?>
<?php if (!empty($items)) { ?>
<div class="loglist">
<?php $this->logsPaginator->render('logs_pagination.phtml', 'page'); ?>
<?php foreach ($items as $log) { ?>
<div class="log <?= $log->level() ?>"><span class="date">
<?= @date('Y-m-d H:i:s', @strtotime($log->date())) ?>
</span><?= htmlspecialchars($log->info(), ENT_NOQUOTES, 'UTF-8') ?></div>
<?php } ?>
<?php $this->logsPaginator->render('logs_pagination.phtml', 'page'); ?>
</div>
<?php } else { ?>
<p class="alert alert-warn"><?= _t('index.log.empty') ?></p>
<?php } ?>
</main>
|