MyBB Community Forums

Full Version: move logo in header
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
i w,t to move logo to fit in template i have tried to do it with changing the line in edit template/header.

found dis code: to move the logo to right position.
<div style="position: absolute; left:200px; top:40px;">

edit in the script from my template header.

<div class="topbar"><navigation></div>
<div id="header">
<div id="panel">
{$welcomeblock} 
</div>

<div class="logo"><a href="{$mybb->settings['bburl']}">
<div style="position: absolute; left:200px; top:40px;"><img src="images/lust/logo.png"/></a></div>


</div>
<div class="menu">
<ul>
<li><a href="{$mybb->settings['bburl']}/search.php">Search</a></li>
<li><a href="{$mybb->settings['bburl']}/memberlist.php">Members</a></li>
<li><a href="{$mybb->settings['bburl']}/calendar.php">Calendar</a></li>
<li><a href="{$mybb->settings['bburl']}/misc.php?action=help">Help</a></li>
</ul>
</div>

<div id="container">
		<a name="top" id="top"></a>
			<hr class="hidden" />
		<hr class="hidden" />
		<br class="clear" />
		<div id="content">
			{$pm_notice}
			{$bannedwarning}
			{$bbclosedwarning}
			{$unreadreports}<!-- ProfileComments -->
			{$comments_alert}<!-- /ProfileComments -->{$unreadpmreports}
			{$pending_joinrequests}
			<br />

The code i found work but it mess up hole header, did i place code in wrong place?

pleass check my other post, need some one to fix it.

http://friznioz.6te.net/

username/test
passs/tester
Replace your header template with this:

<div class="topbar"><navigation></div>
<div id="header">
<div id="panel">
{$welcomeblock} 
</div>

<div class="logo">
    <a href="{$mybb->settings['bburl']}"><img src="images/lust/logo.png" alt="" /></a>
</div>

</div>
<div class="menu">
<ul>
<li><a href="{$mybb->settings['bburl']}/search.php">Search</a></li>
<li><a href="{$mybb->settings['bburl']}/memberlist.php">Members</a></li>
<li><a href="{$mybb->settings['bburl']}/calendar.php">Calendar</a></li>
<li><a href="{$mybb->settings['bburl']}/misc.php?action=help">Help</a></li>
</ul>
</div>

<div id="container">
        <a name="top" id="top"></a>
            <hr class="hidden" />
        <hr class="hidden" />
        <br class="clear" />
        <div id="content">
            {$pm_notice}
            {$bannedwarning}
            {$bbclosedwarning}
            {$unreadreports}<!-- ProfileComments -->
            {$comments_alert}<!-- /ProfileComments -->{$unreadpmreports}
            {$pending_joinrequests}
            <br />

Go to Admin CP > Templates & Style > Themes > Your Theme > global.css > Advanced Mode.

Find:

.logo {
	padding-top: 18px;
	margin-left: -18px;
}

Replace with:

.logo {
	padding-top: 18px;
}

Find:

#header {
	background: url(images/lust/head4_bg.png) repeat-x;
	width: 1015px;
	color: #000000;
	margin: auto auto;
	text-align: left;
	height: 130px;
	border-left: 1px solid #797979;
	border-right: 1px solid #797979;
	font-family: sans-serif;
}

Increase the 130px value in the height property until it fits your theme.
its fits now but i got space between blue and black
In global.css find:

#header {
    background: url(images/lust/head4_bg.png) repeat-x;
    width: 1015px;
    color: #000000;
    margin: auto auto;
    text-align: left;
    height: 180px;
    border-left: 1px solid #797979;
    border-right: 1px solid #797979;
    font-family: sans-serif;
}

Replace with:

#header {
    background: #337bab url(images/lust/head4_bg.png) repeat-x;
    width: 1015px;
    color: #000000;
    margin: auto auto;
    text-align: left;
    height: 180px;
    border-left: 1px solid #797979;
    border-right: 1px solid #797979;
    font-family: sans-serif;
}
Great work, it look easy for you guys to fix that fast. Can you find a way to move it logo littel bit to right? sorry for last question.
.logo {
    padding-left:  20px;
    padding-top: 18px;
}

Update the logo class to that. If you want it further or less to the right change the padding left value Wink.
padding left has removed check message up from Fábio Maia,

i have add padding-left: 20px; back in the place and change px.

yes it moved more in place, will i get problem with adding back the padding-left: 20px code.

now it seems oke. hope snotting will get wrong on other pages with adding the line back.

thanks for support.