Title: Recent Comments
Author: Automattic
Published: <strong>2005 年 1 月 13 日</strong>
Last modified: 2021 年 2 月 10 日

---

搜尋外掛

這個外掛**並未在最新的 3 個 WordPress 主要版本上進行測試**。開發者可能不再對這個
外掛進行維護或提供技術支援，並可能會與更新版本的 WordPress 產生使用上的相容性問題。

![](https://s.w.org/plugins/geopattern-icon/recent-comments.svg)

# Recent Comments

 由 [Automattic](https://profiles.wordpress.org/automattic/) 開發

[下載](https://downloads.wordpress.org/plugin/recent-comments.zip)

 * [詳細資料](https://tw.wordpress.org/plugins/recent-comments/#description)
 * [使用者評論](https://tw.wordpress.org/plugins/recent-comments/#reviews)
 *  [安裝方式](https://tw.wordpress.org/plugins/recent-comments/#installation)
 * [開發資訊](https://tw.wordpress.org/plugins/recent-comments/#developers)

 [技術支援](https://wordpress.org/support/plugin/recent-comments/)

## 外掛說明

Creates functions to assist in displaying a list of the most recent comments. Provides
more configurability than the widget that comes with WordPress.

### Configuration

You may pass parameters when calling the function to configure some of the options.
Parameters are accepted only in the [query-string-style](https://codex.wordpress.org/How_to_Pass_Tag_Parameters#Tags_with_query-string-style_parameters).

#### list_most_recent_comments()

In addition to the parameters that [get_comments()](https://codex.wordpress.org/Function_Reference/get_comments)
and `get_most_recent_comments()` (see below) accept, this function accepts the following
parameters:

 * `excerpt_words` — The number of words from the comment to display
 * `excerpt_chars` — Or alternately the number of characters from the comment to
   display
 * `comment_format` — Allows you to pick from two predefined display formats:

 1. [Comment Author](https://tw.wordpress.org/plugins/recent-comments/?output_format=md#commentlink)
    on [Post Title](https://tw.wordpress.org/plugins/recent-comments/?output_format=md#postlink)
 2. **Comment Author:** [This is the comment excerpt](https://tw.wordpress.org/plugins/recent-comments/?output_format=md#commentlink)

Example:

    ```
    <?php list_most_recent_comments( 'excerpt_words=5' ); ?>
    ```

#### get_most_recent_comments()

A more powerful version of [get_comments()](https://codex.wordpress.org/Function_Reference/get_comments).
It accepts the same parameters as well as the following ones:

 * `passworded_posts` — Boolean to control showing comments on passworded posts 
   or not. Defaults to `false`.
 * `showpings` — Boolean to control showing pings and trackbacks or not. Defaults
   to `false`.
 * `post_types` — Array of post types to include comments from. Defaults to posts
   and pages: `array( 'post', 'page' )`
 * `post_statuses` — Array of post statuses to include comments from. Defaults to
   published posts and static pages: `array( 'publish', 'static' )`

Arguments should likely be passed as an array instead of a string.

Example:

    ```
    <?php

    list_most_recent_comments( array(
        'showpings' => true,
        'post_types' => array( 'post', 'page', 'foobar' ),
    ) );

    ?>
    ```

## 安裝方式

 1. Visit Plugins -> Add New in your WordPress administration area and search for the
    name of this plugin.
 2. Activate the plugin.
 3. Add `<?php list_most_recent_comments(); ?>` to your theme.

## 使用者評論

這個外掛目前沒有任何使用者評論。

## 參與者及開發者

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

參與者

 *   [ Automattic ](https://profiles.wordpress.org/automattic/)
 *   [ Nick Momrik ](https://profiles.wordpress.org/nickmomrik/)
 *   [ Alex Mills ](https://profiles.wordpress.org/viper007bond/)

[將〈Recent Comments〉外掛本地化為台灣繁體中文版](https://translate.wordpress.org/projects/wp-plugins/recent-comments)

### 對開發相關資訊感興趣？

任何人均可[瀏覽程式碼](https://plugins.trac.wordpress.org/browser/recent-comments/)、
查看 [SVN 存放庫](https://plugins.svn.wordpress.org/recent-comments/)，或透過 [RSS](https://plugins.trac.wordpress.org/log/recent-comments/?limit=100&mode=stop_on_copy&format=rss)
訂閱[開發記錄](https://plugins.trac.wordpress.org/log/recent-comments/)。

## 變更記錄

#### Version 2.0.0

 * Recoded from scratch to make use of `get_comments()` instead of a direct database
   query.
 * Additional parameters added.

#### Version 1.0.0

 * Original release

## 中繼資料

 *  版本 **2.1**
 *  最後更新 **5 年前**
 *  啟用安裝數 **200+**
 *  語言
 * [English (US)](https://wordpress.org/plugins/recent-comments/)
 * 標籤:
 * [comments](https://tw.wordpress.org/plugins/tags/comments/)[list](https://tw.wordpress.org/plugins/tags/list/)
   [recent](https://tw.wordpress.org/plugins/tags/recent/)
 *  [進階檢視](https://tw.wordpress.org/plugins/recent-comments/advanced/)

## 評分

這個項目尚無任何評論記錄。

[Your review](https://wordpress.org/support/plugin/recent-comments/reviews/#new-post)

[查看全部使用者評論](https://wordpress.org/support/plugin/recent-comments/reviews/)

## 參與者

 *   [ Automattic ](https://profiles.wordpress.org/automattic/)
 *   [ Nick Momrik ](https://profiles.wordpress.org/nickmomrik/)
 *   [ Alex Mills ](https://profiles.wordpress.org/viper007bond/)

## 技術支援

使用者可在技術支援論壇提出意見反應或使用問題。

 [檢視技術支援論壇](https://wordpress.org/support/plugin/recent-comments/)