]>
git.wh0rd.org - tt-rss.git/blob - classes/pref/system.php
2957b7b96ed62681bed6ec352cfefd66d07204db
3 class Pref_System
extends Handler_Protected
{
5 function __construct($link, $args) {
6 parent
::__construct($link, $args);
9 function before($method) {
10 if (parent
::before($method)) {
11 if ($_SESSION["access_level"] < 10) {
12 print __("Your access level is insufficient to open this tab.");
20 function csrf_ignore($method) {
21 $csrf_ignored = array("index");
23 return array_search($method, $csrf_ignored) !== false;
28 print "<div dojoType=\"dijit.layout.AccordionContainer\" region=\"center\">";
29 print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Error Log')."\">";
31 $result = db_query($this->link
, "SELECT errno, errstr, filename, lineno,
32 created_at, login FROM ttrss_error_log
33 LEFT JOIN ttrss_users ON (owner_uid = ttrss_users.id)
34 ORDER BY ttrss_error_log.id DESC
37 print "<p><table width=\"100%\" cellspacing=\"10\" class=\"prefErrorLog\">";
39 print "<tr class=\"title\">
40 <td width='5%'>".__("Error")."</td>
41 <td>".__("Filename")."</td>
42 <td>".__("Message")."</td>
43 <td width='5%'>".__("User")."</td>
44 <td width='5%'>".__("Date")."</td>
47 while ($line = db_fetch_assoc($result)) {
48 print "<tr class=\"errrow\">";
50 foreach ($line as $k => $v) {
51 $line[$k] = htmlspecialchars($v);
54 print "<td class='errno'>" . Logger
::$errornames[$line["errno"]] . " (" . $line["errno"] . ")</td>";
55 print "<td class='filename'>" . $line["filename"] . ":" . $line["lineno"] . "</td>";
56 print "<td class='errstr'>" . $line["errstr"] . "</td>";
57 print "<td class='login'>" . $line["login"] . "</td>";
59 print "<td class='timestamp'>" .
60 make_local_datetime($this->link
,
61 $line["created_at"], false) . "</td>";
71 $pluginhost->run_hooks($pluginhost::HOOK_PREFS_TAB
,
72 "hook_prefs_tab", "prefSystem");
74 print "</div>"; #container