我为buddypress的登录用户添加了一个自定义标题(header-new.php)到站点http://parentctrhub.staging.wpengine.com。我在默认页面模板中添加的代码是:
if ( is_user_logged_in() ) {
get_header('new');
}
else {
get_header();
}
但是,现在黑色buddypress工具栏/管理栏已经停止显示。它显示为注销用户(如果我检查buddypress设置中的选项),但不显示为登录用户。奇怪的是,现在即使我撤消所有的更改,工具栏也不会显示。
已解决。我刚加了:
show_admin_bar( true );
在functions.php文件和管理栏再次出现