Title: Recent Post Views
Author: Chris Buck
Published: <strong>2012 年 1 月 31 日</strong>
Last modified: 2012 年 5 月 30 日

---

搜尋外掛

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

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

# Recent Post Views

 由 [Chris Buck](https://profiles.wordpress.org/chrisbuck/) 開發

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

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

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

## 外掛說明

This plugin requires the WP-PostViews plugin to be installed and setup to work correctly.(
https://wordpress.org/extend/plugins/wp-postviews/)

This plugin displays a widget in the sidebar with the most recently viewed posts
over the last 2 days, the number of times they were viewed, a link to each, and 
images corresponding to whether they were “hot” posts or not (calculated as a percentage
of the most viewed post).

## 螢幕擷圖

 * [[
 * As you see from the screenshot, you get a nice sidebar widget with posts titles,
   links to the post, and a count of the recent number of views.

## 安裝方式

 1. Upload `recent-post-views.php` to the `/wp-content/plugins/` directory.
 2. Activate the plugin through the ‘Plugins’ menu in WordPress.
 3. Put the post in the sidebar via the ‘Widgets’ menu, save a title for the widget.
 4. Use the shortcode [recentpostviews] in your pages and posts. See FAQ’s for more
    info. Accepts “cat”, “posts”, and “days” as inputs.

## 常見問題集

  How do I use the shortcode?

The basic format is [recentpostviews], which will by default show a list of the 
top 7 posts, from all categories, over the last 2 days.
 Options are “cat”, “posts”
and “days”. * “cat” is the category ID. * “posts” is the number of posts you want
to display. * “days” is the number of days back you want the shortcode to query,
as in “over the last (n) days.”

Example: [recentpostviews cat=”5″ posts=”10″ days=”3″]
 *This would display the 
10 most recent posts from category 5 over the last 3 days.

If you’re not getting any results for the shortcode, try changing the number of 
days.

By default, the “hotlevel” for posts is 75% or .75 in the shortcode. E.g., a post
will not show up as “hot” unless it is greater than or equal to the post with the
most number of views over the same time frame.

  How can I change options, like what is considered a “recent” post?

Just add the widget and select your options.

  I have multiple widgets, and some of them have posts that are viewed the same 
number of times, but one is not a “hot” post. What gives?

Whether a post is hot or not is dependent on the max number of views for any post
over the timeframe you have selected. E.g., if you have a widget based on the last
3 days and one based on the last 7, the level for a “hot” post will be different.
I’m planning on changing this in a future update, such that the max number of posts
for a particular category will be calculated.

  The number of views for my posts are not updating, why?

I actually had this issue myself, and discovered that it’s because the postmeta 
table was not updating the number of views. As a temporary solution, I installed
the WP-PostViews plugin (at https://wordpress.org/extend/plugins/wp-postviews/) 
and enabled the option in the settings menu that said to register views from everyone,
not just guests. Thanks to GamerZ for a great plugin, and for helping to fix this
issue. If you’re having this problem, I suggest that recent-post-views should be
used in conjunction with WP-PostViews.

## 使用者評論

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

## 參與者及開發者

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

參與者

 *   [ Chris Buck ](https://profiles.wordpress.org/chrisbuck/)

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

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

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

## 變更記錄

#### 1.5

 * Added settings sub-menu with styling options.
 * Fixed list and table code for widgets and shortcode.

#### 1.4

 * Added shortcode functionality.
 * Minor changes to the table tags in the widget.

#### 1.3

 * Prefixed all the variable names and made the paths to image files relative.
 * This should be a more stable release, one that can co-exist peacefully with other
   plugins.

#### 1.2

 * Minor bug fix

#### 1.1

 * Added option to set threshold percent level for “hot” posts.
 * Added option to change html color code for number of views.

#### 1.0

 * Adds option to change number of posts and to select specific categories.

#### 0.5

 * Adds option to widget to change number of days for recent posts.

#### 0.1

 * First release, displays most recent posts views over last 2 days.

## 中繼資料

 *  版本 **1.5**
 *  最後更新 **14 年前**
 *  啟用安裝數 **10+**
 *  WordPress 版本需求 ** 2.8.0 或更新版本 **
 *  已測試相容的 WordPress 版本 **3.3.3**
 *  語言
 * [English (US)](https://wordpress.org/plugins/recent-post-views/)
 * 標籤:
 * [post](https://tw.wordpress.org/plugins/tags/post/)[posts](https://tw.wordpress.org/plugins/tags/posts/)
   [recent](https://tw.wordpress.org/plugins/tags/recent/)[recent posts](https://tw.wordpress.org/plugins/tags/recent-posts/)
   [views](https://tw.wordpress.org/plugins/tags/views/)
 *  [進階檢視](https://tw.wordpress.org/plugins/recent-post-views/advanced/)

## 評分

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

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

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

## 參與者

 *   [ Chris Buck ](https://profiles.wordpress.org/chrisbuck/)

## 技術支援

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

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

## 贊助

想要支援這個外掛的發展嗎？

 [ 贊助這個外掛 ](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=SPAZAZLTNNRXG)