
Grid Avoid Doublets
v2.0.0Palasthotel GmbH · 2016年9月12日 上架
Prevents the same post from showing up twice when several Grid boxes list posts on one page.
- 正在使用
- 10+
- 评分
- 暂无
- 累计下载
- 1,844
- 最近更新
- 2026年11月23日
需要 WordPress 4.0+已测试到 7.1.5PHP 8.0+
Pages built with the Grid plugin often contain several boxes that list recent posts. Without coordination, the same post can appear in more than one of these boxes. This plugin keeps track of the posts that have already been placed while a grid renders and removes them from the queries of the post list boxes that follow.
Themes and custom grid boxes can use the same API to register and check their own posts:
grid_avoid_doublets_add( $post_id, $area_id )marks a post as placed.grid_avoid_doublets_is_placed( $post_id, $area_id )checks whether a post has already been placed.grid_avoid_doublets_get_placed( $area_id )returns the IDs of all placed posts.