• Not finding anything in my search here, where can I find the code to comment out to remove the search box?

Viewing 4 replies - 46 through 49 (of 49 total)
  • Thanks to Stacy.Canion & Chip Bennett

    I was able to remove the white space above the header picture moving the header picture all the way to the top which is great!

    Delete this code in the Header section:

    `<hgroup>
    <h1 id=”site-title”><span><a href=”<? php echo esc_url( home_url( ‘/’ ) ); ?>” title=”<?php echo esc_attr( get_bloginfo( ‘name’, ‘display’ ) ); ?>” rel=”home”><?php bloginfo( ‘name’ ); ?></a></span></h1>
    <h2 id=”site-description”><?php bloginfo( ‘description’ ); ?></h2>

    </hgroup>`

    Now to get rid of the search box up top delete this code:

    <?php
    				// Has the text been hidden?
    				if ( 'blank' == get_header_textcolor() ) :
    			?>
    				<div class="only-search<?php if ( ! empty( $header_image ) ) : ?> with-image<?php endif; ?>">
    				<?php get_search_form(); ?>
    				</div>
    			<?php
    				else :
    			?>

    <?php get_search_form(); ?>
    <?php endif; ?>

    If you would like to see how this worked, you’re welcome to visit my site: My blog

    hi frnds

    [Code moderated as per the Forum Rules. The maximum number of lines of code that you can post in these forums is ten lines. Please use the pastebin]

    i hv used this code but m getting error at the third line from the last plz do some help for me to solve this problem

    I successfully removed the Search box from my Esplanade header by deleting (I know I should have ‘commented out’) <?php get_search_form(); ?> in header.php but, like tammieearl, my menu links are still wrapping around to a second line as though the search box were still there. The answer is probably above, but I’m a ‘casual user’ and would very much appreciate it if someone would summarize what I need to do to get the menu to use the whole header width. I know this forum is for Twenty Eleven and that the Forum Etiquette Police will probably be after me, but this forum is the easiest to follow and seems to have the most knowledgeable people (blatant attempt to butter you up). Plus, the solution is probably the same or similar.

    Please post your own topic.

Viewing 4 replies - 46 through 49 (of 49 total)
  • The topic ‘Remove search box [Twenty Eleven]’ is closed to new replies.