wordpress模板开发 | 循环的使用(4)
列表中循环的使用
ID); // var_dump($post->post_date); // var_dump($post->post_title); ?>"> the_title(); ?>
the_content(); ?>
判断是否有文章 have_posts()
赋值item the_post()
输出标题 the_title()
输出链接 the_permalink()
输出内容 the_content()
这里输出内容有个小技巧,默认全部全部输出内容,不易截取,可以再编辑器中添加more

前台页面显示

> 本文由子枫笔记快捷发布!
本站文章如未注明出处均为原创,转载请注明出处,如有侵权请邮件联系站长。