• I changed the header of twentytwelve so that the navbar is below the header image.

    <body <?php body_class(); ?>>
    <div id="page" class="hfeed site">
    	<header id="masthead" class="site-header" role="banner">
    		<hgroup>
    			<h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
    			<h2 class="site-description"><?php bloginfo( 'description' ); ?></h2>
    		</hgroup>
    
    		<?php if ( get_header_image() ) : ?>
    		<a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php header_image(); ?>" class="header-image" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" /></a>
    		<?php endif; ?>
    
    		<nav id="site-navigation" class="main-navigation" role="navigation">
    			<h3 class="menu-toggle"><?php _e( 'Menu', 'twentytwelve' ); ?></h3>
    			<a class="assistive-text" href="#content" title="<?php esc_attr_e( 'Skip to content', 'twentytwelve' ); ?>"><?php _e( 'Skip to content', 'twentytwelve' ); ?></a>
    			<?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?>
    		</nav><!-- #site-navigation -->
    	</header><!-- #masthead -->
    
    	<div id="main" class="wrapper">

    I now want to have the header image starting at the top of the white page (no top-margin) an fill the right and left margin of the image (the white page) with the background color (in which the header image is held (appart from the font).

    (P.S.: If I use twentytwelve as a child the submenus won’t work correctly. They display as ordinary menulinks.)

Viewing 4 replies - 1 through 4 (of 4 total)
  • (P.S.: If I use twentytwelve as a child the submenus won’t work correctly. They display as ordinary menulinks.)

    Then something is wrong with your child theme – get that sorted. Do not modify theme files – you will lose all your changes when WP is updated.

    want to have the header image starting at the top of the white page (no top-margin) an fill the right and left margin of the image (the white page) with the background color

    please post a live link to your site;

    also, try the forum search, as this might have been answered before.

    Thread Starter empedokles

    (@empedokles)

    The only thing I did change in twentytwelve is the above in the header.php. The child theme only contains the styles.css file.

    Link

    Thread Starter empedokles

    (@empedokles)

    I changed it back and can confirm that the child theme usage of twentytwelve doesn’t display the submenus correctly. If used as a childtheme the submenus will display as ordinary menu item instead of a flip out submenu.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Headerimage – Cutting the white space.’ is closed to new replies.