Deprecated: Function ereg() is deprecated in /home/silence/blog.silence.idv.tw/wp-content/plugins/tantan-flickr/flickr.php on line 56

Deprecated: Assigning the return value of new by reference is deprecated in /home/silence/blog.silence.idv.tw/wp-content/plugins/tantan-flickr/flickr.php(83) : runtime-created function on line 1

Strict Standards: Non-static method TPGuestbook::get_instance() should not be called statically in /home/silence/blog.silence.idv.tw/wp-content/plugins/tp-guestbook/tp-guestbook.php on line 506

Strict Standards: call_user_func_array() expects parameter 1 to be a valid callback, non-static method GoogleSitemapGeneratorLoader::Enable() should not be called statically in /home/silence/blog.silence.idv.tw/wp-includes/plugin.php on line 311
SILENCE Blog » Blog 文章彙整 » [Plugin]Post Views Plus Widget
Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 934

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/silence/blog.silence.idv.tw/wp-includes/kses.php on line 935
SILENCE Blog

[Plugin]Post Views Plus Widget

2006, 11月 25 5:36 pm
請造訪新版本 1.0.12 的說明網頁

Whatup 的 Blog 內看到一篇關於 Widget 實作的教學文章,於是嘗試著挑了一個 Plugin 來實作 Widget,此 Plugin 為 Post Views Plus,可計算 Blog 內的文章被閱讀的次數。當然要能使用 Widget﹐必須先安裝 Widget Plugin: Sidebar Widget

下載與安裝

  1. 下載並放到 wp-content\plugins 資料夾內
  2. 啟用!

設定

在後台的「外觀」內﹐可找到「Sidebar Widgets」選項﹐在裡面找到 Top Posts﹐拖曳後可進行下列設定
因 Post Views Plus 這個 Plugin 提供了兩個 function:

  1. 可抓出被閱讀最多次數的 Posts:get_most_viewed()
  2. 設定在幾天內被閱讀最多次數的 Posts:get_timespan_most_viewed()

因此 Widget 將利用這兩個 function﹐可設定的選項也是依照這兩個 function 來設計﹐設定畫面如下:

Post View Plus Widget

  • Display Mode: 選擇是否要包含 Post, Page 還是兩者皆是
  • Title : 設定此 Widget 顯示在 sidebar 的標題
  • Top Posts Number: 設定文章數量
  • Posts Title Length: 文章標題長度
  • Post in Last Days: 設定幾天內的文章進行排名﹐若設 0 則為全部的文章排名
  • Include Bot views: 因 Post Views Plus 有分開 bot 閱讀文章的次數﹐選擇是否包含之

若在使用上遇到相關問題或是 Bug﹐請盡量詢問或是回報﹐感謝 :-)

目前有 6 個回應, 1 個引用

Dennys 回應此篇文章 於 2007, 1月 16

我安裝後在 web 上看到這個錯誤訊息, 環境是 Wordpress 2.0.7 + K2 0.9.1, 麻煩您檢查一下了, thanks.

WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1]
SELECT p.ID, p.post_title, p.post_name, p.post_status, p.post_date, CAST(pm.meta_value AS UNSIGNED) AS views FROM wp_posts AS p LEFT JOIN wp_postmeta AS pm ON pm.post_id = p.ID WHERE p.post_date

SILENCE 回應此篇文章 於 2007, 1月 16

Hi, Dennys
我 check 過此 widget 在 2.0.7 上是沒問題的﹐問題點可能出在:
1. postviews_plus 是否為最新的 1.0.6 版?
2. wp-includes/functions.php 是否有出問題?因此 plugin 有使用到此檔案的 current_time() 這個 function, 而您 mysql 的 error msg 剛好停在那邊。

Dennys 回應此篇文章 於 2007, 2月 2

這兩天剛好 upgrade 成 wordpress 2.1 和 postviews_plus 1.07, 現在看來一切正常了, 謝謝.

WP Plugins DB » Plugin Details » WP-PostViews Plus Widget pingback此篇文章 於 2007, 7月 18

[...] Visit [...]

Jason 回應此篇文章 於 2007, 9月 26

Hi Love the plugin
I have been messing with other for weeks.

any ideas how to remove “Views” from the widget..

Jason

SILENCE 回應此篇文章 於 2007, 9月 27

hi Jason, I already publish the new version.
http://blog.silence.idv.tw/2007/09/27/post-view-plus-widget1012/

you will be able to change text: “Views” .

eric 回應此篇文章 於 2007, 11月 25

作用还真不少啊。呵呵。支持。

想要留言嗎?