Support » Theme: Twenty Twelve » Setting default header image in child theme

  • Resolved Yakti-R


    Twenty Twelve by default doesn’t have a header image specified. For a child theme, I need to set a default header image. I’ve tried overriding the custom header functionality, but wasn’t able to find a durable solution.

    I tried copying the /inc/custom-header.php to the child theme’s folder, and customize it there, but the child theme just kept using the parent theme’s custom-header file.

    My current solution is to replace line 83 of the parents functions.php
    require( get_template_directory() . '/inc/custom-header.php' );
    require( get_stylesheet_directory() . '/inc/custom-header.php' );
    This does the trick, however, I will need to make the change everytime Twenty Twelve gets updated.

    Anyone has a solution that can withstand an update to the parent theme?

Viewing 31 replies (of 31 total)
Viewing 31 replies (of 31 total)
  • The topic ‘Setting default header image in child theme’ is closed to new replies.