wordpress自定义循环列表的php代码

 
<?php $epaged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$temp = $wp_query;
$wp_query = null;
?>
<?php $wp_query = new WP_Query('category_name=portfolio&tag=web&showposts=5&paged=' . $epaged);?>
<?php if ($wp_query->have_posts()) : ?>
<section class="itemBlocks">
<?php while ($wp_query->have_posts()) : $wp_query->the_post(); ?>
<article class="iBlock">
<time datetime="<?php the_time('Y-m-d') ?>" class="fs-14" pubdate><?php the_time('F jS, Y') ?></time>
<h1 class="fs-14 color-dark">
<a rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>" class="lnk-item">
<?php the_title(); ?>
</a>
</h1>
<section class="story hidden">
<?php the_content(); ?>
</secion>
</article>
<?php endwhile;?>
<p class="postsPaging">
<?php
next_posts_link( __( '&larr; Older posts', 'twentyten' ) );
previous_posts_link( __( 'Newer posts &rarr;', 'twentyten' ) );
$wp_query = null; $wp_query = $temp;
?>
</p>
</section>
<?php
endif;
?>

以上就是安达网络工作室关于《wordpress自定义循环列表的php代码》的一些看法。更多内容请查看本栏目更多内容!

本文相关话题: wordpress 自定义 循环列表
版权声明:本文为 安达网络工作室 转载文章,如有侵权请联系我们及时删除。
相关文章
wordpress中文截断产生乱码处理办法

可是严酷的事实是大局部的模板都还是出于老外之手,老内在做模板的时分普通只会思考到显示失常即可,而咱们...

获取wordpress注册用户的数量的办法

本文实例讲述了获取wordpress注册用户的数量的办法分享给大家供大家参考。详细完成办法如下: 办法一,代码如...

WordPress 有人回复时邮件告诉的完成办法 SAE 移植版

1,先配置一下您的SMTP账户的用户名和明码。 2,将上面的内容粘贴到以后主题的 functions.php 中即可,留意...

为WordPress增加文章字数统计的办法

WordPress在后盾编辑日志时编辑框左下角有一个字数统计,不过只显示在后盾,能不能在前台也加上文章字数统计...

Wordpress罕用插件以及插件罕用代码

要害字形容:罕用 插件 代码 以及 &mdash 文章 即可 &nbsp 而后 统计   这篇文章是我之前为一个香港人...

WordPress 2.8的8个特征的新增性能

最新版本的WordPress 2.8的公布,为WordPress网站开发者带来了更多的便当,让像WPYOU这样的基于WordPress的...

需求提交

客服服务

亿鸽在线客服系统