• Resolved decogle

    (@decogle)


    Hi all,
    here’s the link to my website

    I wanted to put the search box (currently at the sidebar) to the right hand corner of the logo (almost like a header banner). I’ve tried to do it via header.php but it always ends up in the wrong place. Then I’ve tried to put the searchform.php in the header banner (via theme settings) but I still can’t get the hold of positioning.

    The 2nd question: how can I decrease the gap between the logo and the menu?

    Thank you all.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You need to replace everything with your own structure. I’m not going to fill in all the details – I’ll leave that up to you to do and learn from this.

    First, you need structure:

    <div id="header">
    	<div id="logo">
    		<img src="/path/to/yourlogo.png" alt="logo"/>
    	</div>
    	<div id="search">
    		<?php include("searchform.php"); ?>
    	</div>
    </div>

    Next, you need to style it:

    #header {
    	width: 100%;
    float: left;
    }
    #header #logo {
    	float: left;
    }
    #header #search {
    	float: left;
    	text-align: right;
    	margin-right: 1em;
    }

    I’ll leave the rest of this to you fill in the specifics and pretty it up.

    The easiest would be to ask this on http://www.wpexplorer.com/videos/gopress-video-overview the author of the Theme.

    Emil

    Thread Starter decogle

    (@decogle)

    Thank you for your help kobashicomputing and Emil.

    I was experimenting for a good hour and accidentally ended up having the menu and the logo joined in one piece – thought it looked good so I left it like that.

    Saved a copy of kobashicomputing’ post.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Help needed with header.php’ is closed to new replies.