Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

Renan Pongeluppe

Como centralizar site

Recommended Posts

Sou um pouco leigo no assunto e gostaria q me ajudassem a centralizar meu site...

como faço pra deixar ele centralizado e auto expansivo ???

 

 

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Dayane makeup</title>
<meta http-equiv="Page-Enter" content="revealTrans(Duration=1,Transition=0)">
<meta name="generator" content="WYSIWYG Web Builder 8 - http://www.wysiwygwebbuilder.com">
<style type="text/css">
body
{
background-color: #4B0082;
background-image: url(images/_bkgrnd.png);
color: #000000;
}
</style>
<style type="text/css">
a
{
color: #0000FF;
text-decoration: underline;
}
a:visited
{
color: #800080;
}
a:active
{
color: #FF0000;
}
a:hover
{
color: #0000FF;
text-decoration: underline;
}
</style>
<style type="text/css">
#wb_Text1
{
background-color: transparent;
border: 0px #000000 solid;
padding: 0;
}
#wb_Text1 div
{
text-align: center;
white-space: nowrap;
}
#wb_Text2
{
background-color: transparent;
border: 0px #000000 solid;
padding: 0;
}
#wb_Text2 div
{
text-align: left;
}
#wb_Text3
{
background-color: transparent;
border: 0px #000000 solid;
padding: 0;
}
#wb_Text3 div
{
text-align: left;
}
#wb_Text4
{
background-color: transparent;
border: 0px #000000 solid;
padding: 0;
}
#wb_Text4 div
{
text-align: left;
}
#wb_CssMenu1 a
{
display: block;
float: left;
margin: 0px 0px 0px 0px;
color: #C0C0C0;
border: 1px #000000 solid;
background-color: #808080;
background: -moz-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -webkit-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -o-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -ms-linear-gradient(bottom,#808080 0%,#000000 100%);
background: linear-gradient(bottom,#808080 0%,#000000 100%);
font-family: Adorable;
font-size: 27px;
font-weight: normal;
font-style: normal;
text-decoration: none;
padding: 15px 79px 15px 79px;
text-align: center;
}
#wb_CssMenu1 a:hover, #wb_CssMenu1 .active
{
color: #666666;
background-color: #C0C0C0;
background: -moz-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -webkit-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -o-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -ms-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
border: 1px #C0C0C0 solid;
}
#Image2
{
border: 0px #000000 solid;
}
#wb_CssMenu2 a
{
display: block;
float: left;
margin: 0px 0px 0px 0px;
color: #C0C0C0;
border: 1px #000000 solid;
background-color: #808080;
background: -moz-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -webkit-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -o-linear-gradient(bottom,#808080 0%,#000000 100%);
background: -ms-linear-gradient(bottom,#808080 0%,#000000 100%);
background: linear-gradient(bottom,#808080 0%,#000000 100%);
font-family: Adorable;
font-size: 27px;
font-weight: normal;
font-style: normal;
text-decoration: none;
padding: 15px 79px 15px 79px;
text-align: center;
}
#wb_CssMenu2 a:hover, #wb_CssMenu2 .active
{
color: #666666;
background-color: #C0C0C0;
background: -moz-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -webkit-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -o-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: -ms-linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
background: linear-gradient(bottom,#C0C0C0 0%,#EEEEEE 100%);
border: 1px #C0C0C0 solid;
}
#Image1
{
border: 0px #000000 solid;
}
</style>
<script type="text/javascript" src="jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="wb.conveyerbelt.min.js"></script>
<script type="text/javascript">
$(document).ready(function()
{
$("#SlideShow1").conveyerbelt({speed:2, spacing: 5});
});
</script>
</head>
<body>
<div id="SlideShow1" style="position:absolute;left:0px;top:227px;width:1281px;height:184px;overflow:hidden;z-index:0;">
<img style="border-width:0;left:0px;top:0px;width:184px;height:184px;" src="images/409937-maquiagem-para-a-noite-pele-negra.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:253px;height:184px;display:none;" src="images/MAQ%2010.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:200px;height:184px;display:none;" src="images/maquiagem%20para%20noiva%206.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:364px;height:184px;display:none;" src="images/maquiagem-mineral-modelo-divulgacao-boticario.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:336px;height:184px;display:none;" src="images/Maquiagem-para-R%E9veillon-2013-6.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:205px;height:184px;display:none;" src="images/mke-up-1.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:336px;height:184px;display:none;" src="images/Mulher-maquiada-com-cores-claras.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:204px;height:184px;display:none;" src="images/Origem-da-maquiagem-3.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:184px;height:184px;display:none;" src="images/Penteado.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:167px;height:184px;display:none;" src="images/Penteados-de-festa-quase-solto-30.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:288px;height:184px;display:none;" src="images/Penteados-para-noivas-2013_355.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:121px;height:184px;display:none;" src="images/penteados-para-noivas-cabelo-lindo.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:184px;height:184px;display:none;" src="images/text_maquiagem_para_noiva_negra.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:144px;height:184px;display:none;" src="images/tran%E7as-5.jpg" alt="" title="">
<img style="border-width:0;left:0px;top:0px;width:265px;height:184px;display:none;" src="images/tudo-sobre-maquiagem-que-voce-precisa-saber-1-1.jpg" alt="" title="">
</div>
<div id="wb_Shape3" style="position:absolute;left:0px;top:411px;width:1284px;height:16px;z-index:1;">
<img src="images/img0003.gif" id="Shape3" alt="" style="border-width:0;width:1284px;height:16px;"></div>
<div id="wb_Shape2" style="position:absolute;left:1px;top:694px;width:1284px;height:16px;z-index:2;">
<img src="images/img0010.gif" id="Shape2" alt="" style="border-width:0;width:1284px;height:16px;"></div>
<div id="wb_Text1" style="position:absolute;left:23px;top:453px;width:843px;height:242px;text-align:center;z-index:3;">
<div style="line-height:25px;"><span style="color:#FFFFFF;font-family:Tahoma;font-size:17px;">    Os PENTEADOS, CORTES E MAQUIAGENS, é um mundo em que as mulheres sempre se deslumbram, </span></div>
<div style="line-height:25px;"><span style="color:#FFFFFF;font-family:Tahoma;font-size:17px;">preincipalmente quando chega aquela ocasião especial como casamento, 15 anos e eventos importantes.<br></span></div>
<div style="line-height:25px;"><span style="color:#FFFFFF;font-family:Tahoma;font-size:17px;">    Noivas, Madrinhas e Debutantes, merecem uma atenção diferenciada, pois serão o centro das atenções </span></div>
<div style="line-height:25px;"><span style="color:#FFFFFF;font-family:Tahoma;font-size:17px;">do envento. Por isso viso sempre o melhor para as minhas clientes e busco produtos e técnicas </span></div>
<div style="line-height:42px;"><span style="color:#FFFFFF;font-family:Tahoma;font-size:17px;">profissionais para melhor atende-las.</span></div>
<div style="line-height:33px;"><span style="color:#FFFFFF;font-family:'Segoe Script';font-size:17px;"><br></span></div>
<div style="line-height:65px;"><span style="color:#FFFFFF;font-family:'Segoe Script';font-size:27px;">Trabalhar com a alta estima das pessoas é um máximo!</span></div>
</div>
<div id="wb_Text2" style="position:absolute;left:913px;top:501px;width:262px;height:56px;z-index:4;text-align:left;">
<span style="color:#A9A9A9;font-family:Adorable;font-size:53px;">Dayane</span></div>
<div id="wb_Text3" style="position:absolute;left:974px;top:464px;width:310px;height:199px;z-index:5;text-align:left;">
<img src="images/img0009.png" id="Text3" alt="" style="border-width:0;width:310px;height:199px;"></div>
<div id="wb_Text4" style="position:absolute;left:1141px;top:576px;width:66px;height:37px;z-index:6;text-align:left;">
<span style="color:#A9A9A9;font-family:Angelina;font-size:35px;">Artist</span></div>
<div id="wb_CssMenu1" style="position:absolute;left:1396px;top:223px;width:1289px;height:78px;text-align:center;z-index:7;">
<a href="./index.html" class="active">Home</a>
<a href="./Maquiagens.html">Maquiagens</a>
<a href="./Penteados.html">Penteados</a>
<a href="./Galeria.html">Galeria</a>
<a href="./Contato.html">Contato</a>
</div>
<div id="wb_Image2" style="position:absolute;left:1396px;top:58px;width:1284px;height:165px;z-index:8;">
<img src="images/Banner%20Dayane.png" id="Image2" alt="" border="0" style="width:1284px;height:165px;"></div>
<div id="wb_CssMenu2" style="position:absolute;left:0px;top:165px;width:1289px;height:78px;text-align:center;z-index:9;">
<a href="./index.html" class="active">Home</a>
<a href="./Maquiagens.html">Maquiagens</a>
<a href="./Penteados.html">Penteados</a>
<a href="./Galeria.html">Galeria</a>
<a href="./Contato.html">Contato</a>
</div>
<div id="wb_Image1" style="position:absolute;left:0px;top:0px;width:1284px;height:165px;z-index:10;">
<img src="images/Banner%20Dayane.png" id="Image1" alt="" border="0" style="width:1284px;height:165px;"></div>
</body>
</html>

Compartilhar este post


Link para o post
Compartilhar em outros sites

Não entendi sua pergunta. Você quer o site centralizado ou que seja de acordo com cada monitor?

 

Para centralizar, cire uma div com nome de "wrapper", "central", "principal" ou qquer coisa parecida e dentro dela você coloca TODO o conteúdo do site.

 

No css vc aplica o seguinte:

 

#wrapper{

position:relative;

margin: 0 auto;

width: 960px; //tamanho sugestivo, você quem decide o tamanho o tamanho da largura do site

height: auto; //sempre bom colocar para evitar a fadiga com o IE.

}

 

Feito isso....be happy!

Compartilhar este post


Link para o post
Compartilhar em outros sites

Muito obrigado eduardo pela resposta, mais jah tentei isso de várias maneiras e não deu certo, pois eu não manjo muito de HTML...não sei ao certo onde colocar esse cod.

Então vamos lá...

 

Logo depois da tag BODY vc abre uma div..tipo assim:

 

<body>

<div id="wrapper">

...cobnteudo do seu site...

</div>

</body>

 

aí no style da página...vc faz isso:

 

#wrapper{

position:relative;

width: 960px;

margin: 0 auto;

height:auto;

}

 

melhor..?

Compartilhar este post


Link para o post
Compartilhar em outros sites

Boa tarde,

 

Aqui tem uma excelente explicação sobre design responsivo (inglês) - http://alistapart.com/article/responsive-web-design

 

Ou ainda você pode utilizar um framework como o twitter bootstrap para lhe facilitar a vida - http://twitter.github.io/bootstrap/index.html

 

É só montar a grid (fixa, fluida e/ou responsiva ) e sair para o abraço.

 

Espero que ajude.

Compartilhar este post


Link para o post
Compartilhar em outros sites

EduardoAugustoPHP se o Renan Pongeluppe está em busca de um site responsivo o css deve ser trabalhado com % e ter o seu min-width e o max-width.

Sim, esqueci de falar pra criar a div antes da wrapper com o 100%

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.