|
@@ -23,13 +23,13 @@ discard block |
|
|
block discarded – undo |
|
23
|
23
|
{ |
|
24
|
24
|
global $context, $txt; |
|
25
|
25
|
|
|
26
|
|
- if (!empty($context['simple_action'])) |
|
27
|
|
- echo ' |
|
|
26
|
+ if (!empty($context['simple_action'])) { |
|
|
27
|
+ echo ' |
|
28
|
28
|
<strong> |
|
29
|
29
|
', $context['error_title'], ' |
|
30
|
30
|
</strong><br> |
|
31
|
31
|
<div ', $context['error_code'], 'class="padding">', $context['error_message'], '</div>'; |
|
32
|
|
- else |
|
|
32
|
+ } else |
|
33
|
33
|
{ |
|
34
|
34
|
echo ' |
|
35
|
35
|
<div id="fatal_error"> |
|
@@ -82,21 +82,23 @@ discard block |
|
|
block discarded – undo |
|
82
|
82
|
', $txt['apply_filter_of_type'], ':'; |
|
83
|
83
|
|
|
84
|
84
|
$error_types = array(); |
|
85
|
|
- foreach ($context['error_types'] as $type => $details) |
|
86
|
|
- $error_types[] = ($details['is_selected'] ? '<img src="' . $settings['images_url'] . '/selected.png" alt=""> ' : '') . '<a href="' . $details['url'] . '" ' . ($details['is_selected'] ? 'style="font-weight: bold;"' : '') . ' title="' . $details['description'] . '">' . $details['label'] . '</a>'; |
|
|
85
|
+ foreach ($context['error_types'] as $type => $details) { |
|
|
86
|
+ $error_types[] = ($details['is_selected'] ? '<img src="' . $settings['images_url'] . '/selected.png" alt=""> ' : '') . '<a href="' . $details['url'] . '" ' . ($details['is_selected'] ? 'style="font-weight: bold;"' : '') . ' title="' . $details['description'] . '">' . $details['label'] . '</a>'; |
|
|
87
|
+ } |
|
87
|
88
|
|
|
88
|
89
|
echo ' |
|
89
|
90
|
', implode(' | ', $error_types), ' |
|
90
|
91
|
</td> |
|
91
|
92
|
</tr>'; |
|
92
|
93
|
|
|
93
|
|
- if ($context['has_filter']) |
|
94
|
|
- echo ' |
|
|
94
|
+ if ($context['has_filter']) { |
|
|
95
|
+ echo ' |
|
95
|
96
|
<tr> |
|
96
|
97
|
<td colspan="3" class="windowbg"> |
|
97
|
98
|
<strong> ', $txt['applying_filter'], ':</strong> ', $context['filter']['entity'], ' ', $context['filter']['value']['html'], ' [<a href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', '">', $txt['clear_filter'], '</a>] |
|
98
|
99
|
</td> |
|
99
|
100
|
</tr>'; |
|
|
101
|
+ } |
|
100
|
102
|
|
|
101
|
103
|
echo ' |
|
102
|
104
|
<tr> |
|
@@ -107,11 +109,12 @@ discard block |
|
|
block discarded – undo |
|
107
|
109
|
</tr>'; |
|
108
|
110
|
|
|
109
|
111
|
// No errors, then show a message |
|
110
|
|
- if (count($context['errors']) == 0) |
|
111
|
|
- echo ' |
|
|
112
|
+ if (count($context['errors']) == 0) { |
|
|
113
|
+ echo ' |
|
112
|
114
|
<tr class="windowbg"> |
|
113
|
115
|
<td class="centertext" colspan="2">', $txt['errlog_no_entries'], '</td> |
|
114
|
116
|
</tr>'; |
|
|
117
|
+ } |
|
115
|
118
|
|
|
116
|
119
|
// we have some errors, must be some mods installed :P |
|
117
|
120
|
foreach ($context['errors'] as $error) |
|
@@ -125,19 +128,21 @@ discard block |
|
|
block discarded – undo |
|
125
|
128
|
<a href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? '' : ';desc', $context['has_filter'] ? $context['filter']['href'] : '', '" title="', $txt['reverse_direction'], '"><span class="generic_icons sort_' . $context['sort_direction'] . '"></span></a> |
|
126
|
129
|
', $error['time'], '<br>'; |
|
127
|
130
|
|
|
128
|
|
- if (!empty($error['member']['ip'])) |
|
129
|
|
- echo ' |
|
|
131
|
+ if (!empty($error['member']['ip'])) { |
|
|
132
|
+ echo ' |
|
130
|
133
|
<a href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', ';filter=ip;value=', $error['member']['ip'], '" title="', $txt['apply_filter'], ': ', $txt['filter_only_ip'], '"><span class="generic_icons filter centericon"></span></a> |
|
131
|
134
|
<strong><a href="', $scripturl, '?action=trackip;searchip=', $error['member']['ip'], '">', $error['member']['ip'], '</a></strong> <br>'; |
|
|
135
|
+ } |
|
132
|
136
|
|
|
133
|
137
|
echo ' |
|
134
|
138
|
</div> |
|
135
|
139
|
<div style="float: left; width: 50%; line-height: 1.8em; padding: 0 4px;">'; |
|
136
|
140
|
|
|
137
|
|
- if ($error['member']['session'] != '') |
|
138
|
|
- echo ' |
|
|
141
|
+ if ($error['member']['session'] != '') { |
|
|
142
|
+ echo ' |
|
139
|
143
|
<a href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', ';filter=session;value=', $error['member']['session'], '" title="', $txt['apply_filter'], ': ', $txt['filter_only_session'], '"><span class="generic_icons filter centericon"></span></a> |
|
140
|
144
|
', $error['member']['session'], '<br>'; |
|
|
145
|
+ } |
|
141
|
146
|
|
|
142
|
147
|
echo ' |
|
143
|
148
|
<a href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', ';filter=error_type;value=', $error['error_type']['type'], '" title="', $txt['apply_filter'], ': ', $txt['filter_only_type'], '"><span class="generic_icons filter centericon"></span></a> |
|
@@ -151,8 +156,8 @@ discard block |
|
|
block discarded – undo |
|
151
|
156
|
<a style="display: table-cell;" href="', $error['url']['html'], '">', $error['url']['html'], '</a> |
|
152
|
157
|
</div>'; |
|
153
|
158
|
|
|
154
|
|
- if (!empty($error['file'])) |
|
155
|
|
- echo ' |
|
|
159
|
+ if (!empty($error['file'])) { |
|
|
160
|
+ echo ' |
|
156
|
161
|
<div style="float: left; width: 100%; padding: 4px 0; line-height: 1.6em; border-top: 1px solid #e3e3e3;"> |
|
157
|
162
|
<a style="display: table-cell; padding: 4px; width: 20px; vertical-align: top;" href="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', ';filter=file;value=', $error['file']['search'], '" title="', $txt['apply_filter'], ': ', $txt['filter_only_file'], '"><span class="generic_icons filter"></span></a> |
|
158
|
163
|
<div> |
|
@@ -160,6 +165,7 @@ discard block |
|
|
block discarded – undo |
|
160
|
165
|
', $txt['line'], ': ', $error['file']['line'], ' |
|
161
|
166
|
</div> |
|
162
|
167
|
</div>'; |
|
|
168
|
+ } |
|
163
|
169
|
|
|
164
|
170
|
echo ' |
|
165
|
171
|
</td> |
|
@@ -187,9 +193,10 @@ discard block |
|
|
block discarded – undo |
|
187
|
193
|
</div> |
|
188
|
194
|
</div>'; |
|
189
|
195
|
|
|
190
|
|
- if ($context['sort_direction'] == 'down') |
|
191
|
|
- echo ' |
|
|
196
|
+ if ($context['sort_direction'] == 'down') { |
|
|
197
|
+ echo ' |
|
192
|
198
|
<input type="hidden" name="desc" value="1">'; |
|
|
199
|
+ } |
|
193
|
200
|
|
|
194
|
201
|
echo ' |
|
195
|
202
|
<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '"> |