
內容簡介
關於
您可以使用此外掛程式,透過文章 ID 取得某篇文章的分享數量。
如何使用
例如,在迴圈中使用 echo pssc_facebook() 函數,或是在任何地方使用 echo pssc_facebook( $post_id ) 函數,來計算文章或頁面在 Facebook 上分享了多少次。此函數將傳回一個計數整數,例如 5 或 0。
或者,你可以在你要計算分享次數的文章中使用短碼 [pssc_facebook] 或 [pssc_facebook post_id=””] 來針對特定文章 ID 計算分享次數。
可用短碼
[pssc_facebook]
[pssc_pinterest]
[pssc_linkedin]
[pssc_delicious]
[pssc_stumble]
[pssc_gplus]
[pssc_all]
可用函數
pssc_facebook()
pssc_pinterest()
pssc_linkedin()
pssc_delicious()
pssc_stumble()
pssc_gplus()
pssc_all()
請注意,PHP 函數需要使用 echo。
更新日誌
版本 1.4.1:因 Twitter 停用其計數 API,移除 Twitter 函數。
版本 1.4.0:修正一些錯誤,並在管理後台編輯頁面 (edit.php) 中新增文章社交分享計數。
版本 1.3.1:修正快取相關錯誤。
版本 1.3:新增快取支援,並在文章編輯頁面中新增總分享數。
版本 1.2:修正沒有文章 ID 使用的函數錯誤。
版本 1.1:修正 pssc_all 短碼錯誤。
外掛標籤
開發者團隊
原文外掛簡介
About
You can use this plugin to get the number of shares for a given post by ID.
How to use
To count for example how many times the post or page has been shared on Facebook use the function echo pssc_facebook() in the loop or echo pssc_facebook( $post_id ) anywhere. This function will return the count integer for example 5 or 0.
Or you can use the shortcode [pssc_facebook] in the post you want to count shares for or [pssc_facebook post_id=””] for a specific post by ID.
Available Shortcodes
[pssc_facebook]
[pssc_pinterest]
[pssc_linkedin]
[pssc_delicious]
[pssc_stumble]
[pssc_gplus]
[pssc_all]
Available Functions
pssc_facebook()
pssc_pinterest()
pssc_linkedin()
pssc_delicious()
pssc_stumble()
pssc_gplus()
pssc_all()
Note that PHP functions needs to be echoed.
Change Log
Version 1.4.1: Removed Twitter functions due Twitter’s disabling their count API.
Version 1.4.0: Fixed some bugs and added Posts Social Shares Count to edit posts/pages/custom post types list view in admin (edit.php).
Version 1.3.1: Fixed a bug with caching.
Version 1.3: Added caching support and Added total shares count to post edit page.
Version 1.2: Fixed a bug with functions without post ID usage.
Version 1.1: Fixed a bug with pssc_all shortcode
