Skip to content

Instantly share code, notes, and snippets.

Created July 30, 2011 04:41
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Remove Header Image
<?php # -*- coding: utf-8 -*-
Plugin Name: Remove Header Image
Description: Disables the header image for properly written themes like TwentyEleven.
Version: 1.0
Required: 3.1
Author: Thomas Scholz
Author URI:
License: GPL
! defined( 'ABSPATH' ) and exit;
add_filter( 'theme_mod_header_image', 'remove_header_image_path', 11 );
function remove_header_image_path()
return 'remove-header';
add_action( 'admin_menu', 'remove_header_image_support', 20 );
function remove_header_image_support()
remove_submenu_page( 'themes.php', 'custom-header' );
// The page is still accessible, so we disable at least uploads.
_remove_theme_support( 'custom-header' );
_remove_theme_support( 'custom-header-uploads' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment