3
I own a site where I use two headers to show my options to the user, but I came across a problem, I need to put the company logo and I’m not able to do it, I need the logo to be in a size proportional to the header, if I put in the first or the second the logo becomes small.
I tried to create a structure, but my knowledge of CSS didn’t help much, I tried something like this:
<style>
.Geral {
height:120px;
}
#logo {
float: left;
width: 220px;
height: 120px;
cursor: pointer;
cursor: hand;
background-image:url(images/anc.fw.png);
background-repeat: no-repeat;
}
#superior {
float: left;
width: 1005px;
height: 60px;
}
#inferior {
float: left;
width: 1005px;
height: 60px;
}
</style>
Speaking may be that I can not exemplify what I need, so I will provide an image.
The site is this and what I tried to do was this:
Hello @Giovannibernini, thanks for the great help, but tell me one thing, if possible, how can I leave the logo above the navbar?
– adventistapr
@adventistapr You can use css with media queries to fix this, for example
@media screen and (min-width: 400px) and (max-width: 600px) {.logo{float:none; position: relative;}}
You control that in a certain screen size, such a thing will change. In the example I gave, between 400 and 600px the class soon, will no longer have thefloat: left
and theposition: absolute
, soon the logo div, will no longer stand on top of the other Divs.– Giovanni Bernini
Hello again @Giovannibernini, I must be doing something wrong, but the change I made as suggested code did not take effect.
– adventistapr