Skip to content
This repository has been archived by the owner on Apr 24, 2023. It is now read-only.

Commit

Permalink
v1.3.5
Browse files Browse the repository at this point in the history
  • Loading branch information
AlekVolsk committed Jun 1, 2019
1 parent 39cffe9 commit 92df3f8
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 6 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# View logs

![Version](https://img.shields.io/badge/VERSION-1.3.4-0366d6.svg?style=for-the-badge)
![Version](https://img.shields.io/badge/VERSION-1.3.5-0366d6.svg?style=for-the-badge)
![Joomla](https://img.shields.io/badge/joomla-3.2+-1A3867.svg?style=for-the-badge)
![Php](https://img.shields.io/badge/php-5.6+-8892BF.svg?style=for-the-badge)

Expand Down
2 changes: 1 addition & 1 deletion README.ru.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# View logs

![Version](https://img.shields.io/badge/VERSION-1.3.4-0366d6.svg?style=for-the-badge)
![Version](https://img.shields.io/badge/VERSION-1.3.5-0366d6.svg?style=for-the-badge)
![Joomla](https://img.shields.io/badge/joomla-3.2+-1A3867.svg?style=for-the-badge)
![Php](https://img.shields.io/badge/php-5.6+-8892BF.svg?style=for-the-badge)

Expand Down
15 changes: 12 additions & 3 deletions admin/models/ajax.php
Original file line number Diff line number Diff line change
Expand Up @@ -296,21 +296,30 @@ public function dwFile()
$fileName = pathinfo(ini_get('error_log'))['filename'];
} else {
$data = $this->getCSV($log_path . '/' . $file, ' ');
$base_ci = -1;
foreach ($data as $i => $item) {
if ($i < 6 && (count($item) < 4 || $item[0][0] == '#')) {
if (strpos($item[0], '#Fields:') !== false) {
$item[0] = str_replace('#Fields: ', '', $item[0]);
foreach ($item as $l => $fname) {
if (strtolower($fname) === 'message') {
$base_ci = $l;
break;
}
}
}
unset($data[$i]);
} else {
if (count($item) == 1) {
$item = explode(' ', $item[0]);
} else {
$ci = count($item) - 1;
$ci = $base_ci >= 0 ? $base_ci : count($item) - 1;
$msg = $item[$ci];
unset($item[$ci]);
$item = explode(' ', implode(' ', $item));
$item[] = $msg;
$item[] = '"' . $msg . '"';
unset($msg);
}

$data[$i] = $item;
}
}
Expand Down
2 changes: 1 addition & 1 deletion vlogs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<authorUrl>https://alekvolsk.pw</authorUrl>
<copyright>© 2019 Aleksey A. Morozov. All right reserved.</copyright>
<license>GNU General Public License version 3 or later; see http://www.gnu.org/licenses/gpl-3.0.txt</license>
<version>1.3.4</version>
<version>1.3.5</version>
<description>COM_VLOGS_DESC</description>
<creationDate>February 2019</creationDate>
<administration>
Expand Down

0 comments on commit 92df3f8

Please sign in to comment.