如何为来自4个唯一类别的最新帖子或特色帖子创建具有多个查询的Wordpress主页滑块? [英] How to Create a Wordpress Homepage Slider with Multiple Queries for Most Recent or Featured Posts from 4 Unique Categories?

查看:105
本文介绍了如何为来自4个唯一类别的最新帖子或特色帖子创建具有多个查询的Wordpress主页滑块?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为正在构建的WordPress网站创建滑块.我尝试构建的滑块将总共有4个幻灯片/框架.每个框架都需要显示来自唯一类别的最新帖子或来自唯一类别的特色帖子.我的意思是,这4张幻灯片/框架中的每张将代表一个单独的类别.

I am working on creating a slider for a WordPress site I am building. The slider I am trying to build will have 4 total slides/frames. Each frame will need to display either the most recent post from a unique category or a featured post from a unique category. By this I mean that each of the 4 slides/frames will represent a separate category.

Slide/Frame 1 = Most Recent or Featured Post from Category A
Slide/Frame 2 = Most Recent or Featured Post from Category B
Slide/Frame 3 = Most Recent or Featured Post from Category C
Slide/Frame 4 = Most Recent or Featured Post from Category D

我的滑块的布局/设计在顶部会有4个导航图标/按钮.这些图标/按钮中的每一个都代表类别之一.这些可用于在幻灯片/框架之间导航.图标/按钮下方将是最新/特色帖子的精选图片.在特色图像"下方将是代表类别的图像(类别名称的图像).在其下方将是帖子标题,其后是帖子日期(可能还有帖子摘录).

The layout/design of my slider will have 4 navigation icons/buttons at the top. Each of these icons/buttons will represent one of the categories. These can be used to navigate from slide/frame to slide/frame. Below the icons/buttons will be the Featured Image for the most recent/featured post. Below the Featured Image will be an image that represents the category (an image of the category name). Below that will be the Post Title followed by the Post Date (and possibly Post Excerpt).

布局:

  • 类别A图标/按钮-类别B图标/按钮-类别C图标/按钮-类别D图标/按钮
  • 类别中最新或精选帖子的特色图片
  • 代表类别的图像
  • 帖子标题
  • 发布日期
  • 摘录后(也许)

我相信我需要创建4个不同的查询;对滑块中的每个幻灯片/框架进行一个查询.有人可以帮我弄清楚如何最好地实现我所追求的目标吗?

I believe I'll need to create 4 different queries; one query for each slide/frame in the slider. Can anybody help me figure out how best to achieve what I am after?

推荐答案

我会搜索一个可以完成魔术的插件.这可以..可以从多个类别提取结果,并且可以高度配置.. http://wordpress .org/extend/plugins/promotion-slider/

I would search for a plugin that can do the magic. This one does.. Can pull results from multiple catwgories and is highly configurable.. http://wordpress.org/extend/plugins/promotion-slider/

这篇关于如何为来自4个唯一类别的最新帖子或特色帖子创建具有多个查询的Wordpress主页滑块?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆