[WordPress] 外掛分享: TPG Get Posts

WordPress 外掛 TPG Get Posts 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「TPG Get Posts」是 2010-06-20 上架。 目前已經下架不再更新,不建議安裝使用。
  • 目前有 700 個安裝啟用數。
  • 上一次更新是 2023-08-18,距離現在已有 622 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
  • 外掛最低要求 WordPress 3.0 以上版本才可以安裝。
  • 有 6 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

cswaim |

外掛標籤

list | post | posts | get_posts | formatting |

內容簡介

請查看版本更改通知的 Changelog,在進行任何更新之前,請保存任何自定義樣式。

此外掛可添加能力:在頁面或文章中放置縮短代碼標籤,並將文章格式化為標準博客的樣式。可以通過一個或多個標籤值(例如標籤、類別或 WP get_posts 函數支持的任何其他選項)選擇文章,僅顯示與頁面相關的項目。還支持將文章標題顯示為列表。默認情況下,它會顯示5篇最近的文章,按日期倒序排列,但它將接受 get_posts 模板標籤提供的大多數選項。如果參數的值是數組,則它必須由此插件進行解析,並未實現所有參數。

要使用它,只需將以下內容放入任何頁面或文章的 HTML 中,在同一頁面上使用多次:[tpg_get_posts]
此默認用法將以相反的時間順序返回最近的5篇文章。它將顯示文章的標準樣式,遵守標籤以產生摘要。還顯示帖子日期、作者、修改日期、評論、類別和標籤等元數據。

如需參數列表和更多使用示例,請參閱「其他注意事項」中的使用部分。全面的文檔位於插件設置頁面或插件網站上。

從版本3.6開始,所有功能均在免費版本中支持(請考慮捐贈)。包括擴展 cat__and、cat__not_in 和 cat__in和其他分類,將短碼添加到文本小工具,廣泛格式化系統。

提供了雜誌佈局選項,顯示帖子標題和文本以及帖子縮略圖。特色圖片版本選項。分頁(不支持所有主題)-此選項已通過 WP 主題和非常有限的一些插件進行測試。有些網站報告分頁無法正常工作,但尚未找到問題所在。它可能是主題或插件衝突。由於在各種站點配置中實現分頁的挑戰,因此無法提供對此選項的支援。

注意,3.0版本更改了縮略圖的默認值。如果此升級破壞了您的站點,請下載標籤2.5.0並設置選項以凍結發行版,請務必在升級之前進行測試。

使用

警告:如果您複製/貼上命令,功能可能無法正常工作。如果發生這種情況,請輸入整個命令以避免引入隱藏字符。

要使用它,只需將以下內容放入任何頁面或文章的 HTML 中,在同一頁面上使用多次:[tpg_get_posts]

這等效於:

[tpg_get_posts fields="title,byline,content,metadata"
fields_classes="post_title=tpg-title-class,
post_content=tpg-content-class,post_byline=tpg-byline-class,
post_metadata=tpg-metadata-class" numberposts=5 ]

此默認用法將以相反的時間順序返回最近的5篇文章。它將顯示文章的標準樣式,遵守標籤以產生摘要。還顯示帖子日期、作者、修改日期、評論、類別和標籤等元數據。

原文外掛簡介

Please review the Changelog for release change notices and save any custom styling before applying any upgrade.
This plugin adds the ability to put a shortcode tag in a page or post and have it display posts formatted similarly to the standard blog. The posts can be selected by one or more tag values, suchs as tags, category or any other option supported by the WP get_posts function, to show only items relevant for the page. It will also support displaying the post titles as a list.
By default it will show the 5 most recent posts ordered in reverse date order,
but it will accept most of the options provided by the get_posts template tag. If the value of the paramter is an array, it must be parsed by the plugin and not all parms have been implemented.
To use it, just put the following into the HTML of any page or post, use as many times as you like on the same page:
[tpg_get_posts]

This default usage will return the last 5 posts in reverse chronological order. It will display the post similarly to a standard post, honoring the tag to produce a teaser. Meta data showing post date, author, modified date, comments, categories and tags is also displayed.
See the usage section in ‘Other Notes’ for a list of parms and more examples of use. Full documentation is on the plugin settings page or at the plugin website

Plugin Website: http://www.tpginc.net/blog/wordpress-plugins/
Documentation link: http://www.tpginc.net/blog/wordpress-plugins/plugin-tpg_get_posts/tpg-get-posts-documentation/

As of version 3.6, all features are supported in the free version (please consider a donation):

extended cat__and, cat__not_in and cat__in and other taxonmy
the short code to be added to a text widget
extensive formating of the by line and meta-data line
a magazine layout option which displays the post header and text next to the post thumbnail
a featured image layout option
pagination (not supported in all themes) – This option is tested against the WP themes and a very limited set of plugins. There are a few sites that have reported pagination not working, but the problem has not been identified. It could be theme or plugin conflict. Due to the challenges of implementing pagination in various site configurations, support for this option cannot be provided.

NOTE
The 3.0 release alters the default for thumbnails. If this upgrade breaks your site, download tag 2.5.0 and set the option to freeze the release. Be sure to test before upgrading.
Usage
WARNING If you copy/paste the commands, the function may not work. If this happens, type the entire command in to avoid introducing hidden characters.
To use it, just put the following into the HTML of any page or post, use as many times as you like on the same page:
[tpg_get_posts]

this is equivalent to:

[tpg_get_posts fields="title,byline,content,metadata"
fields_classes="post_title=tpg-title-class,
post_content=tpg-content-class,post_byline=tpg-byline-class,
post_metadata=tpg-metadata-class" numberposts=5 ]

This default usage will return the last 5 posts in reverse chronological order. It will display the post similarly to a standard post, honoring the tag to produce a teaser. Meta data showing post date, author, modified date, comments, categories and tags is also displayed.
A common usage is to show post on a page that have a common tag or category:
[tpg_get_posts tag="tag1, tag2,tag3"]
or
[tpg_get_posts cat="catname1, catname2, catname3,catid,slug"]

See Settings in plugin for full list of parameters
A couple of examples:
Show 5 posts with the tag “tag1” or “tag2” ordered by title. Display the post title and content teaser.
[tpg_get_posts tag="tag1,tag2" numberposts=5 orderby="title]

Show 2 posts with the category name of “Events” or “News” ordered by title. Display the post title and the entire content.
[tpg_get_posts cat="Events,News" numberposts=2
orderby="title show_entire="true"]

Show a bullet list of post titles. The title will be wrapped in a of class “p-ul-class”. The title will provide a link to the post. The title can be formatted with a css style .p-ul-class h2 {}.
[tpg_get_posts tag="tag5" fields="title" ul_class="p-ul-class"]

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「TPG Get Posts」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


2.0.1 | 2.1.0 | 2.3.0 | 2.4.0 | 2.5.0 | 3.0.0 | 3.1.0 | 3.2.0 | 3.3.0 | 3.3.1 | 3.4.1 | 3.4.2 | 3.5.1 | 3.6.1 | 3.6.2 | 3.6.4 | 3.6.5 | trunk | ver_1.2.1 | ver_1.2.2 | ver_1.2.3 | ver_1.2.4 | ver_1.3.0 | ver_1.3.1 | ver_1.3.2 | ver_1.3.3 | ver_1.3.4 | ver_1.3.5 | ver_1.3.6 | ver_1.3.7 | ver_1.3.8 |

延伸相關外掛(你可能也想知道)

  • Get Posts 》此外掛可將短碼標籤放入任何靜態頁面或文章中,以使用 get_posts 範本標籤來顯示文章列表。更多此外掛關於詳細資訊,請查看它的主要頁面。, , 預設會顯示最新...。

文章
Filter
Mastodon