我想用它的缩略图只在滑块显示最新的帖子。但我的第一个图形元素有一个类。我可以将类应用于第一个缩略图吗,因为它在下面的html结构中?然后,当用户发布带有缩略图的新帖子时,我可以自动增加其他图像吗?
<div class="diy-slideshow">
<figure class="show">
<!-- last recent thumbnail -->
<img src="http://themarklee.com/wp-content/uploads/2013/12/snowying.jpg" width="100%" />
</figure>
<figure>
<!-- second from the last -->
<img src="<?php if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
the_post_thumbnail_url();} ?>" width="100%" />
</figure>
<!-- the rest will go on endless -->
<figure>
<!-- other latest posts thumbnails -->
</figure>
<span class="prev">«</span>
<span class="next">»</span>
</div>
我的问题是,如何在中显示其他最新的帖子缩略图<figure></figure>
, 上面的代码只显示最近发布的缩略图,我想继续显示缩略图,没有限制。我试图创建的结构:
<div class="diy-slideshow">
<figure class="show">
<!-- last recent thumbnail -->
</figure>
<figure>
<!-- second from the last -->
</figure>
<figure>
<!-- thirth from the last -->
</figure>
<figure>
<!-- fourt, fifth,sixth ... from the last -->
</figure>
<span class="prev">«</span>
<span class="next">»</span>
</div>
提前感谢您!