隐藏非管理页面的admin_bar
add_filter( 'show_admin_bar', '__return_false' );
移除搜索框
function remove_search_form($form = ''){
if($echo){
echo '';
}else{
return '';
}
}
add_filter( 'get_search_form', 'remove_search_form');
移除Wordpress 的Logo
add_action('admin_menu','wp_hide_nag');
function wp_hide_nag() {
remove_action( 'admin_notices', 'update_nag', 3 );
}
add_action( 'admin_bar_menu', 'remove_wp_logo', 999 );
function remove_wp_logo( $wp_admin_bar ) {
$wp_admin_bar->remove_node( 'wp-logo' );
}
修改文章摘要的长度
add_action('admin_menu','wp_hide_nag');
function wp_hide_nag() {
remove_action( 'admin_notices', 'update_nag', 3 );
}