在论文主题中启用WordPress体类函数

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了在论文主题中启用WordPress体类函数相关的知识,希望对你有一定的参考价值。

In v1.6, the Thesis Theme has a bug which removes a necessary space in the html body tag if you add a filter targeting the thesis_body_classes hook. To get the native WP body_class function to work, use this code:
  1. function my_body_class( $class = '' ) {
  2. // Separates classes with a single space, collates classes for body element
  3. echo ' class="' . join( ' ', get_body_class( $class ) ) . '"';
  4. }
  5.  
  6. add_filter('thesis_body_classes','my_body_class');

以上是关于在论文主题中启用WordPress体类函数的主要内容,如果未能解决你的问题,请参考以下文章

PHP WordPress条件为主页SlideDeck主题代码片段

markdown WordPress主题参考,如何,片段,存储库说明

WordPress扩展体类

wordpress如何更换主题

WordPress体类

wordpress体类