https://www.wpdaxue.com/get_sidebar.html
左边栏和右边栏
一个主题包含2个边栏。
1 2 3 4 | <?php get_header(); ?> <?php get_sidebar('left'); ?> <?php get_sidebar('right'); ?> <?php get_footer(); ?> |
右边栏和左边栏的名字应该分别命名为 sidebar-right.php 和 sidebar-left.php。
https://www.wpdaxue.com/get_sidebar.html
一个主题包含2个边栏。
1 2 3 4 | <?php get_header(); ?> <?php get_sidebar('left'); ?> <?php get_sidebar('right'); ?> <?php get_footer(); ?> |
右边栏和左边栏的名字应该分别命名为 sidebar-right.php 和 sidebar-left.php。