Boa tarde,
Não tenho muito conhecimento em css e estou com problemas para centralizar a minha pagina.
Para verem como estar segue o link
http://www.jucoski.net/
E abaixo o Codigo
body {
background-color:#2684b7;
}
#corpo{
margin-top: 0px;
margin-left: 11%;
margin-right: auto;
margin-bottom: 0px;
}
#logo {
}
#menu {
width:960px;
height:81px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
border-radius: 10px;
border: 1px solid;
/* Safari 4-5, Chrome 1-9 */
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#c5c5c5), to(#e6e6e6));
/* Safari 5.1, Chrome 10+ */
background: -webkit-linear-gradient(top, #e6e6e6, #c5c5c5);
/* Firefox 3.6+ */
background: -moz-linear-gradient(top, #e6e6e6, #c5c5c5);
/* IE 10 */
background: -ms-linear-gradient(top, #e6e6e6, #c5c5c5);
/* Opera 11.10+ */
background: -o-linear-gradient(top, #e6e6e6, #c5c5c5);
}
#menu-texto {
}
#header {
top:10%;
width:960px;
height:332px;
background-color:#2c2c2c;
}
#conteudo {
width:960px;
height:316px;
/* Safari 4-5, Chrome 1-9 */
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#dadada), to(#727272));
/* Safari 5.1, Chrome 10+ */
background: -webkit-linear-gradient(top, #727272, #dadada);
/* Firefox 3.6+ */
background: -moz-linear-gradient(top, #727272, #dadada);
/* IE 10 */
background: -ms-linear-gradient(top, #dadada, #727272);
/* Opera 11.10+ */
background: -o-linear-gradient(top, #727272, #dadada);
}
#footer {
width:960px;
height:360px;
background-color:#464845;
}

Duvida Com Css
Started By Guilherme Jucoski Fernandes, 14/11/2012, 12:45
1 reply to this topic
#1
Posted 14/11/2012, 12:45
#2
toddycps
Posted 18/11/2012, 23:42
Sempre que for centralizar uma "div" use margin:auto.
Exemplo de como seria o ideal para seu código:
Exemplo de como seria o ideal para seu código:
body {background-color:#2684b7; margin:auto;} #corpo{ margin:auto;} #logo {margin:auto;width:960px;} #menu {margin:auto;width:960px;height:81px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px; border: 1px solid; /* Safari 4-5, Chrome 1-9 */ background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#c5c5c5), to(#e6e6e6)); /* Safari 5.1, Chrome 10+ */ background: -webkit-linear-gradient(top, #e6e6e6, #c5c5c5); /* Firefox 3.6+ */ background: -moz-linear-gradient(top, #e6e6e6, #c5c5c5); /* IE 10 */ background: -ms-linear-gradient(top, #e6e6e6, #c5c5c5); /* Opera 11.10+ */ background: -o-linear-gradient(top, #e6e6e6, #c5c5c5); } #menu-texto {margin:auto; } #header { top:10%; width:960px; height:332px; background-color:#2c2c2c;margin:auto; } #conteudo {margin:auto; width:960px; height:316px; /* Safari 4-5, Chrome 1-9 */ background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#dadada), to(#727272)); /* Safari 5.1, Chrome 10+ */ background: -webkit-linear-gradient(top, #727272, #dadada); /* Firefox 3.6+ */ background: -moz-linear-gradient(top, #727272, #dadada); /* IE 10 */ background: -ms-linear-gradient(top, #dadada, #727272); /* Opera 11.10+ */ background: -o-linear-gradient(top, #727272, #dadada); } #footer { width:960px; height:360px; background-color:#464845;margin:auto; }
Edição feita por: toddycps, 18/11/2012, 23:45.
1 user(s) are reading this topic
0 membro(s), 1 visitante(s) e 0 membros anônimo(s)