Ver Mensaje Individual
  #4 (permalink)  
Antiguo 19/10/2008, 12:14
Avatar de talmente
talmente
 
Fecha de Ingreso: noviembre-2007
Mensajes: 233
Antigüedad: 16 años, 5 meses
Puntos: 4
Respuesta: Div alineado al centro

Prueba esto quizás de partida te sea útil:

Código:
<style type="text/css">
<!--
#contenedor {
	width: 100%;
	background: #006666;
	display: block;
	margin-right: auto;
	margin-left: auto;
}
#contenedor #uno {
	width: 23%;
	background: #00CCCC;
	float: left;
	position: relative;
	left: 25%;
	top: 0px;
	padding-top: 5px;
	padding-right: 5px;
	padding-bottom: 5px;
	padding-left: 10px;
}
#contenedor #dos {
	background: #009999;
	display: block;
	width: 23%;
	float: right;
	position: relative;
	top: 0px;
	right: 25%;
	padding-top: 5px;
	padding-right: 5px;
	padding-bottom: 5px;
	padding-left: 10px;
}
.clear {
	clear: both;
}
-->
</style>
Te pongo el contenido del body:

Código HTML:
<body>
<div id="contenedor">
<div id="uno"><p>Lorem ipsum </p></div>
<div id="dos"><p>Lorem ipsum dolor sit amet, </p></div>
<div class="clear"></div>
</div>
</body>