WordPress.org

Ready to get started?Download WordPress

Forums

Twenty Twelve
[resolved] [Theme: twenty twelve] remove custom header in parent theme (9 posts)

  1. dan77
    Member
    Posted 1 year ago #

    I'm trying for a while now to remove completely the custom header.
    but because twentytwelve is using it with
    require( get_template_directory() . '/inc/custom-header.php' );
    I couldn't just do the remove_theme_support() trick.
    creating that directory with an empty custom_header.php in the child theme didn't work out, either.
    same as trying to remove the function called in the custom_header template
    remove_action( 'after_setup_theme', 'twentytwelve_custom_header_setup', 11);
    in different variations. no success :(

    Can someone help out, please! thanks!

  2. paulwpxp
    Font hero
    Posted 1 year ago #

    You can go with CSS only.

    .header-image {display:none;}

    or use the code from the 1st comment here
    http://core.trac.wordpress.org/ticket/23157#comment:1

  3. dan77
    Member
    Posted 1 year ago #

    :)
    that's true !
    but I want it to disappear in the backend, that the customers wont play around with it.

    and as far as I know, it wont be good for page load, since it will still load the image..

    thanks anyway!

  4. esmi
    Forum Moderator
    Posted 1 year ago #

    I want it to disappear in the backend, that the customers wont play around with it.

    So just give them Editor logins for general day-to-day use.

  5. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    try this in functions.php of the child theme:

    function twentytwelvechild_remove_custom_header() {
    remove_theme_support( 'custom-header' );
    }
    add_action( 'after_setup_theme', 'twentytwelvechild_remove_custom_header', 11 );
  6. dan77
    Member
    Posted 1 year ago #

    thanks alchymyth,
    that did it!!
    thanks a lot for that fast and easy solution!

  7. dan77
    Member
    Posted 1 year ago #

    thank you as well esmi! that is even a more considered solution
    regarding the fact of clients messing things up :)

  8. Taylor
    Member
    Posted 8 months ago #

    Hate to come in so late on this...but have a similar issue with Twenty Twelve and wanting to remove the "customize" menu link.

    I've already got the header and background removed but can't for the life of me figure out how to remove the customize menu.

  9. WPyogi
    Volunteer Moderator
    Posted 8 months ago #

    @Taylor - could you start a new thread - and include a link to your site. This one is resolved and your question isn't the same.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.