作者页面获取作者的帖子和页面

时间:2016-04-28 00:55:23

标签: wordpress author

如何在其存档页面上返回静态页面以及作者的帖子? 我们的网站使用静态页面作为信息内容和博客区域的帖子页面。

非常感谢你。

1 个答案:

答案 0 :(得分:0)

您只需在主题目录中创建 author.php 页面即可。在该页面内,您可以根据需要编写简单的WordPress循环和所有静态内容....这样,您的作者的帖子将显示在此页面上...例如,您可以这样进行....假设我们在 author.php 页面中写这个内容;

<?php get_header();?>
 <?php 
    //all your static code and loop content will go here inside according to nature of content ...like static content with in DIVs and php content inside php tags etc
 ?>

<?php get_footer();?> 

希望有意义,有关更多信息,请访问https://codex.wordpress.org/Author_Templates