Title: ScriptTrace: JS Error Logger
Author: devfixture
Published: <strong>2026 年 10 月 9 日</strong>
Last modified: 2026 年 10 月 14 日

---

搜索插件

![](https://ps.w.org/script-trace/assets/banner-772x250.png?rev=3736097)

![](https://ps.w.org/script-trace/assets/icon-256x256.png?rev=3736097)

# ScriptTrace: JS Error Logger

 作者：[devfixture](https://profiles.wordpress.org/devfixture/)

[下载](https://downloads.wordpress.org/plugin/script-trace.1.0.5.zip)

 * [详情](https://cn.wordpress.org/plugins/script-trace/#description)
 * [评价](https://cn.wordpress.org/plugins/script-trace/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/script-trace/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/script-trace/#developers)

 [支持](https://wordpress.org/support/plugin/script-trace/)

## 描述

ScriptTrace: JS Error Logger captures frontend JavaScript errors, unhandled promise
rejections, and failed script, image, and stylesheet loads. Reports are sent to 
your WordPress REST API and stored in a local database table.

 * View captured errors under the dedicated ScriptTrace: JS Error Logger admin menu.
 * Group repeated errors and count their occurrences.
 * Record messages, available stack traces, page and source URLs, line and column
   numbers, and user agents.
 * Enable or disable logging and exclude logged-in administrators.
 * Keep records for 7, 30, 90, or 180 days, or indefinitely.
 * Optionally copy each unique error to the PHP error log at most once per hour 
   across visitors and pages. Reports continue to be stored and counted normally.

Logging is enabled by default. Logged-in administrators are excluded by default,
data retention defaults to 30 days, and PHP log mirroring is disabled by default.

Reports are stored on your WordPress installation; the plugin does not send them
to an external logging service. Error messages, stack traces, and URLs can contain
information supplied by other scripts on your site.

### Quality Assurance

This plugin is community-tested on PluginPeer, an independent platform for WordPress
plugin quality assurance.

[View detailed QA test results on PluginPeer](https://pluginpeer.com/plugins/scripttrace-js-error-logger)

## 安装

 1. Upload the plugin ZIP through Plugins > Add New > Upload Plugin, or copy the script-
    trace folder into wp-content/plugins.
 2. Activate ScriptTrace: JS Error Logger.
 3. Open ScriptTrace: JS Error Logger > Settings to configure capture, retention, and
    optional PHP log mirroring.
 4. Browse the frontend as an anonymous visitor, then open ScriptTrace: JS Error Logger
    > All Errors to view captured reports.

## 常见问题

### Why are my administrator’s errors missing?

Ignore Administrators is enabled by default. Test in a private window without logging
in, or disable this option and reload the frontend.

### Does the plugin capture every message in the browser console?

No. It captures browser error and unhandled rejection events. Calls to console.error()
and exceptions evaluated directly by DevTools are not equivalent to page error events.
Errors that occur before the listener loads cannot be captured.

### Where do copied PHP log entries go?

They use PHP’s configured error_log destination. When WordPress debug logging is
active, this can be wp-content/debug.log or a custom WP_DEBUG_LOG path. The plugin
does not enable WordPress debug mode.

### How does hourly grouping work?

Errors are grouped by type, message, source URL, line, and column. Page URL and 
visitor are not part of the grouping key. The first report is copied immediately;
duplicates are suppressed in the PHP log for one hour, while database occurrence
counts continue to increase. The next report after that hour can be copied again.
Deleting stored errors also removes their mirroring timestamps.

## 评价

此插件暂无评价。

## 贡献者及开发者

「ScriptTrace: JS Error Logger」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ devfixture ](https://profiles.wordpress.org/devfixture/)

[帮助将「ScriptTrace: JS Error Logger」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/script-trace)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/script-trace/)，查看
[SVN仓库](https://plugins.svn.wordpress.org/script-trace/)，或通过[RSS](https://plugins.trac.wordpress.org/log/script-trace/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/script-trace/)。

## 更新日志

#### 1.0.5

 * Prevent AJAX list actions from resubmitting a previous bulk action.

#### 1.0.4

 * Fix bulk status changes and deletion in the error list.
 * Restore error details, status updates, and individual row actions.
 * Fix Delete All Resolved and Clear All Logs, including empty logs.

#### 1.0.2

 * Fix error reporting in WordPress Playground and SQLite installations by using
   a transaction instead of MySQL advisory locks.

#### 1.0.1

 * Fix settings registration and error-list rendering.
 * Register the reporting endpoint for anonymous frontend requests.
 * Capture failed resource loads and preserve reports received in bursts.
 * Add optional hourly PHP error log mirroring.

#### 1.0.0

 * Initial release.

## 额外信息

 *  版本 **1.0.5**
 *  最后更新：**11 小时前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 6.2 或更高版本 **
 *  已测试的最高版本为 **7.1.3**
 *  PHP 版本 ** 7.0 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/script-trace/)
 * 标签
 * [debugging](https://cn.wordpress.org/plugins/tags/debugging/)[errors](https://cn.wordpress.org/plugins/tags/errors/)
   [javascript](https://cn.wordpress.org/plugins/tags/javascript/)[logging](https://cn.wordpress.org/plugins/tags/logging/)
   [monitoring](https://cn.wordpress.org/plugins/tags/monitoring/)
 *  [高级视图](https://cn.wordpress.org/plugins/script-trace/advanced/)

## 评级

尚未提交反馈。

[您的评价](https://wordpress.org/support/plugin/script-trace/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/script-trace/reviews/)

## 贡献者

 *   [ devfixture ](https://profiles.wordpress.org/devfixture/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/script-trace/)