tinyphp

在wordpress中,模板标签指一些字段,比如标题,内容,作者,发布日期,评论数等等,获取静态值和循环里面经常使用。

输出模板标签一般有两种方式:the_yourtag() 输出标签值和get_the_yourtag()获标签值
通常来说,the_yourtag()==echo get_the_yourtag();

常用模版标签:

bloginfo(\'name\'); 获取博客名字
bloginfo(\'template_directory\'); 获取主题存放路径
bloginfo( \'stylesheet_url\' ); style.css路径调用
bloginfo(’description’);  博客描述
the_title(); 标题
the_author();  作者
next_post_link(\'%link\');  下一篇文章链接
previous_post_link(\'%link\'); 上一篇文章链接

 

更多标签请看:

wordpress的所有模板标签

分类:

技术点:

相关文章:

  • 2021-12-31
  • 2021-06-15
  • 2021-12-22
  • 2021-05-31
  • 2021-12-23
  • 2021-08-13
  • 2021-11-28
  • 2021-05-18
猜你喜欢
  • 2021-06-17
  • 2022-12-23
  • 2021-11-20
  • 2021-12-13
  • 2021-12-31
  • 2021-12-13
  • 2021-12-31
相关资源
相似解决方案