Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想做的是通过“日期”元键对出现在由不同分类子级过滤的页面上的所有帖子进行排序。
我发现了这个通用的 query_posts 函数:
query_posts('&meta_key=date&orderby=meta_value&order=DESC')
这会抓取所有帖子并将它们放在一个页面上,并按我的自定义元键对它们进行排序。我仍希望将页面按给定的分类/术语分开,但按此日期 meta_key 对所有这些进行排序。我希望我已经正确解释了这一点。非常感谢,谁能帮忙!