Custom Header Logo

  • Thread starter Thread starter Deleted member 745
  • Start date Start date
D

Deleted member 745

Guest
Hi,

I have tried adding a custom logo on my website but it does not show right - it's dimensions are 465 x 100 and you can see it here but its not showing right it's to small.http://chatfreaks.net/community/
Thanks for any help.​
 
I'm trying to center my logo on in the header, but can't work out what bit I need to change.

Any hints?
Try this.

Code:
#logo img {
height:35px;
margin-left:auto;
margin-right:auto;
vertical-align:middle;
}


Essentially just add these lines to the #logo img CSS
margin-left:auto;
margin-right:auto;

And remove this one from #logo
float:left;
 
Try this.

Code:
#logo img {
display:block;
height:35px;
margin-left:auto;
margin-right:auto;
vertical-align:middle;
}


Essentially just add these lines to the #logo img CSS
display:block;
margin-left:auto;
margin-right:auto;

So my head css now has

Code:
        #logo img
        {
            vertical-align: middle;
                        /*height: 35px;*/
                        display:block;
                        margin-left:auto;
                        margin-right:auto;
        }
because I commented out the height to make it slightly larger, but still it keeps aligning the logo to the left :confused:
 
So my head css now has

Code:
        #logo img
        {
            vertical-align: middle;
                        /*height: 35px;*/
                        display:block;
                        margin-left:auto;
                        margin-right:auto;
        }
because I commented out the height to make it slightly larger, but still it keeps aligning the logo to the left :confused:

Got it!

Probably a better way to do it, but had to comment out the float: left in the #logo class to do it. :)
 
Dave browse too:

Appearance -> Styles Properties -> Header and Navigation

Make sure your style is selected above all the settings and you can choose the logo dimensions there.

I hope this helps!
When I did the steps to get there it shows this:
logosize.webp
THIS is handy for cases where you add a new image to the background in that header...but the logosize doesn't look editable there. I'll give dragonfly's edit a try.
 
When I did the steps to get there it shows this:
View attachment 4214
THIS is handy for cases where you add a new image to the background in that header...but the logosize doesn't look editable there. I'll give dragonfly's edit a try.
You can't change the logo size within the settings. If the "height of header logo" option is set to a value lower than that of the actual logo image, the logo image will be resized to that value.
 
What's the best way of adding padding/margin above and below the logo? My logo image is 60px high, therefore #logo and #logo img have a height of 60px, but if I increase the height of #logo or add margin/padding, it causes the positioning of the navigation/top corners/breadcrumbs to mess up, which isn't easily fixed.
 
Styles & Templates/ Templates/header.css

find this class...

#logo img
{
vertical-align: middle;
/*height: 35px;*/
}


and either adjust the height to your logo size, or as I have done.. comment it out.

:)


Used this, the logo size increased, but now this happened. The slogan didn't appear. Do i need to tweak something?
 

Attachments

  • Untitled picture.webp
    Untitled picture.webp
    7.3 KB · Views: 26
What's the best way of adding padding/margin above and below the logo? My logo image is 60px high, therefore #logo and #logo img have a height of 60px, but if I increase the height of #logo or add margin/padding, it causes the positioning of the navigation/top corners/breadcrumbs to mess up, which isn't easily fixed.

Appearance -> Styles -> Style Properties Groups -> Settings -> Height of Header Logo

This setting will change the height of the area your logo resides. If your logo is 60px hight, use 80px for Height of Header Logo to give a 10px space above and below your logo.
 
Appearance -> Styles -> Style Properties Groups -> Settings -> Height of Header Logo

This setting will change the height of the area your logo resides. If your logo is 60px hight, use 80px for Height of Header Logo to give a 10px space above and below your logo.

This just stretches the image, because the height is applied to #logo img.
 
Strange... could you screenshot the value you changed in the ACP?

It is exactly as I posted above. That was the only change I made to the style. I do not post a potential answer until tested first. The height is set to 150px.

The height is applied here:

#logo
{
display: block;
float: left;
line-height: @headerLogoHeight;
height: @headerLogoHeight;
vertical-align: middle;
}

and not contained here:

#logo img
{
vertical-align: middle;
height: 35px;
}

Now replace the float:left in #logo with text-align: center and you have a centered logo with equal spacing above and below (using 150px height for that container in my example), as shown here:
 

Attachments

  • ss2.webp
    ss2.webp
    23.8 KB · Views: 26
Top Bottom