不同页面输出不同的侧边栏块。
- 判断是否为首页: [code type=php]<?php if ( is_home() ) { ?>[/code]
- 判断是否为文章页 : [code type=php]<?php if ( is_single() {?>[/code]
- 判断是否为Page页: [code type=php]<?php if ( is_page() {?>[/code]
- 判断是否为存档页: [code type=php]<?php if ( is_category(){?>[/code]
等
完结后勿忘<?php }?>结束判断语句。
Leave a Reply