Error Log Monitor

外掛說明

這個外掛會新增一個能夠顯示來自網站主機 PHP 環境的最新錯誤記錄的控制台小工具,還能傳送最新錯誤記錄電子郵件通知至網站管理員電子信箱。

外掛特色

  • 自動偵測錯誤記錄位置。
  • 如果網站未啟用 PHP 錯誤記錄功能,外掛會說明如何進行這項設定。
  • 可設定記錄項目顯示數量。
  • 可設定是否傳送已記錄錯誤的通知電子郵件。
  • 可設定接收通知電子郵件的人員及通知頻率。
  • 可輕鬆清除記錄檔內的記錄。
  • 僅有網站管理員可以檢視外掛的控制台小工具。
  • 外掛已完成最佳化,即使處理龐大的記錄檔也能遊刃有餘。

使用方式

外掛安裝完畢後,請前往 [控制台] 並在 [顯示項目設定] 面板中啟用 [PHP 錯誤記錄]。這個小工具能自動顯示最近 20 筆 PHP 錯誤記錄。如果看到類似 [錯誤記錄已停用] 的錯誤訊息,請依照相關指示設定錯誤訊息顯示功能。

依照預設,電子郵件通知為停用狀態。如需啟用這項功能,點擊小工具右上方的 [設定] 連結,然後在 [接收定期錯誤記錄的電子郵件地址] 欄位中輸入指定電子郵件地址,並可依實際需求於 [傳送電子郵件的頻率] 下拉式選單中設定電子郵件間的最短時間間隔。

螢幕擷圖

  • 外掛提供的 [PHP 錯誤記錄] 小工具
  • 控制台小工具設定畫面

安裝方式

請在網站上依照以下步驟安裝外掛:

  1. 下載外掛 ZIP 壓縮檔至個人電腦上。
  2. 前往 [外掛] -> [安裝外掛],然後點擊 [上傳外掛] 按鈕。
  3. 上傳外掛 ZIP 壓縮檔。
  4. 在 [外掛] -> [已安裝外掛] 頁面中啟用外掛。
  5. 前往 [控制台],並於 [顯示項目設定] 面板中啟用 [PHP 錯誤記錄] 小工具。
  6. (選擇性) 點擊小工具右上方的 [設定] 連結以設定外掛。

使用者評論

2019 年 9 月 20 日
Works great, and is exactly what I was looking for. Very useful, thank you.
2018 年 11 月 26 日
I've used this plugin for a long time and it's made improvements over the years. Unfortunately, after switching to a new hosting environment the error log files cannot be set "per website" as php-fpm is executed it's own user/group - the error log file for PHP errors is a single file and containing all domain's errors and it is not possible to change this. This is somewhat common configuration for those on VPS and not shared hosting. Now, it should be fairly easy to filter out the log so only those from the relevant domain are shown, but the plugin does not do that. It should. I'll update to 5 stars when this issue is fixed. Thanks!
2018 年 8 月 13 日
This tool helps me keep an eye on plugins. Given the increasing frequency of WordPress and plugin updates, it is important to have a way to catch errors occurring after an updating plugins - especially because some plugin capabilities are utilized only on specific pages. I don't want to have to view all such pages just to check that everything is fine. It doesn't happen that often, but when there is a problem, Error Log Monitor saves time because it provides instant notification when an error occurs and gives me instant access to the details. This is especially great for those problems that don't visibly manifest themselves on the website.
閱讀全部 27 則使用者評論

參與者及開發者

以下人員參與了開源軟體〈Error Log Monitor〉的開發相關工作。

參與者

Error Log Monitor 外掛目前已有 1 個本地化語言版本。 感謝全部譯者為這個外掛做出的貢獻。

將 Error Log Monitor 外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

1.6.6

  • Improved the way the plugin displays truncated stack traces. Now it should no longer display the last entry as a very tall and narrow block of text.
  • Added a workaround for conflicts with plugins that use old versions of scbFramework.
  • Tested up to WP 5.2.

1.6.5

  • Fixed a bug where it wasn’t possible to filter out log entries that didn’t match any of the standard severity levels (notice, warning, error, etc). Now you can hide uncategorized log entries by unchecking the “Other” option in filter settings.
  • Fixed a security issue.
  • Tested with the final WP 5.1 release.

1.6.4

  • Changed plugin configuration permissions. Now you need to have the “install_plugins” capability to change the configuration. Previous versions used the “update_core” capability.
  • Fixed a bug where users who couldn’t change plugin configuration were still shown a useless “Submit” button.
  • Tested with WP 5.1-alpha.

1.6.3

  • Added a workaround for a conflict with “Go Fetch Jobs (for WP Job Manager)” 1.4.6.
  • Tested with the final WP 5.0 release.

1.6.2

  • Added a setup wizard that helps new users create a log file and enable error logging. You can still do it manually you prefer. The setup notice will automatically disappear if logging is already configured.
  • Fixed a bug where activating the plugin on individual sites in a Multisite network could, in some cases, trigger a fatal error.
  • Additional testing with WP 5.0-alpha.

1.6.1

  • Fixed the “upgrade” link being broken in certain configurations.

1.6

  • Added a colored dot showing the severity level to each error message. Fatal errors are red, warnings are orange, notices and strict-standards messages are grey, and custom or unrecognized messages are blue.
  • Added a new setting for email notifications: “how often to check the log for new messages”.
  • Added a notice explaining how to configure WordPress to log all types of errors (including PHP notices) instead of just fatal errors and warnings.
  • Added Freemius integration.
  • Added a link to the Pro version to bottom of the widget.
  • Improved parsing of multi-line log entries. Now the plugin will show all of the lines as part of the same message instead of treating every line as an entirely separate error.
  • Improved stack trace formatting.
  • In Multisite, the dashboard widget now also shows up in the network admin dashboard.
  • Changed permissions so that only Super Admins can change plugin settings or clear the log file. Regular administrators can still see the widget.

1.5.7

  • The widget now displays log timestamps in local time instead of UTC.
  • Fixed a runtime exception “Backtrack buffer overflow” that was thrown when trying to parse very long log entries.

1.5.6

  • The dashboard widget now shows the log file size and the “Clear Log” button even when all entries are filtered out.
  • Tested with WP 4.9 and WP 5.0-alpha.

1.5.5

  • Fixed two PHP notices: “Undefined index: schedule in […]Cron.php on line 69” and “Undefined index: time in […]Cron.php on line 76”.
  • Added “error_reporting(E_ALL)” to the example code to log all errors and notices.
  • Tested up to WP 4.9-beta2.

1.5.4

  • Fixed the error “can’t use method return value in write context”. It was a compatibility issue that only affected PHP versions below 5.5.

1.5.3

  • You can send email notifications to multiple addresses. Just enter a comma-separated list of emails.
  • Made sure that email notifications are sent no more often than the configured frequency even when WordPress is unreliable and triggers cron events too frequently.
  • Tested up to WP 4.9-alpha-40871.

1.5.2

  • Fixed a fatal error caused by a missing directory. Apparently, SVN externals don’t work properly in the wordpress.org plugin repository.

1.5.1

  • Added an option to ignore specific error messages. Ignored messages don’t show up in the dashboard widget and don’t generate email notifications, but they stay in the log file.
  • Added limited support for parsing stack traces generated by PHP 7.
  • Made the log output more compact.
  • Improved log parsing performance.
  • Fixed an “invalid argument supplied for foreach” warning in scbCron.

1.5

  • Added a severity filter. For example, you could use this feature to make the plugin send notifications about fatal errors but not warnings or notices.
  • Added limited support for XDebug stack traces. The stack trace will show up as part of the error message instead of as a bunch of separate entries. Also, stack trace items no longer count towards the line limit.

1.4.2

  • Hotfix for a parse error that was introduced in version 1.4.1.

1.4.1

  • Fixed a PHP compatibility issue that caused a parse error in Plugin.php on sites using an old version of PHP.

1.4

  • Added an option to send an email notification when the log file size exceeds the specified threshold.
  • Fixed a minor translation bug.
  • The widget now shows the full path of the WP root directory along with setup instructions. This should make it easier to figure out the absolute path of the log file.
  • Tested with WP 4.6-beta3.

1.3.3

  • Added i18n support.
  • Added an elm_show_dashboard_widget filter that lets other plugins show or hide the error log widget.
  • Tested with WP 4.5.1 and WP 4.6-alpha.

1.3.2

  • Tested up to WP 4.5 (release candidate).

1.3.1

  • Added support for Windows and Mac style line endings.

1.3

  • Added an option to display log entries in reverse order (newest to oldest).
  • Added a different error message for the case when the log file exists but is not accessible.
  • Only load the plugin in the admin panel and when running cron jobs.
  • Fixed the error log sometimes extending outside the widget.
  • Tested up to WP 4.4 (alpha version).

1.2.4

  • Tested up to WP 4.2 (final release).
  • Added file-based exclusive locking to prevent the plugin occasionally sending duplicate email notifications.

1.2.3

  • Tested up to WP 4.2-alpha.
  • Refreshing the page after clearing the log will no longer make the plugin to clear the log again.

1.2.2

  • Updated Scb Framework to the latest revision.
  • Tested up to WordPress 4.0 beta.

1.2.1

  • Tested up to WordPress 3.9.

1.2

  • Tested up to WordPress 3.7.1.

1.1

  • Fixed plugin homepage URL.
  • Fix: If no email address is specified, simply skip emailing the log instead of throwing an error.
  • Tested with WordPress 3.4.2.

1.0

  • Initial release.