调用标题侧栏的模板中的代码
<div class="wrapper">
<?php get_sidebar("header"); ?>
<div id="switcher">
小部件。php有以下代码。。。
<?php
if (function_exists(\'register_sidebar\')) {
register_sidebar(array(
\'name\' => \'Header\',
\'id\' => \'header\',
\'description\' => \'This is the widgetized header.\',
\'before_widget\' => \'<div id="%1$s" class="widget %2$s">\',
\'after_widget\' => \'</div>\',
\'before_title\' => \'<h4>\',
\'after_title\' => \'</h4>\'
));
register_sidebar(array(
\'name\' => \'Sidebar\',
\'id\' => \'sidebar\',
\'description\' => \'This is the widgetized sidebar.\',
\'before_widget\' => \'<div id="%1$s" class="widget %2$s">\',
\'after_widget\' => \'</div>\',
\'before_title\' => \'<h4>\',
\'after_title\' => \'</h4>\'
));
register_sidebar(array(
\'name\' => \'Footer\',
\'id\' => \'footer\',
\'description\' => \'This is the widgetized footer.\',
\'before_widget\' => \'<div id="%1$s" class="widget %2$s">\',
\'after_widget\' => \'</div>\',
\'before_title\' => \'<h4>\',
\'after_title\' => \'</h4>\'
));
}