Re: [OT][HTML] Centrado mediante CSS

From: Date: Wed, 15 Oct 2003 10:21:33 +0000
Subject: Re: [OT][HTML] Centrado mediante CSS
References: 1  Groups: php.general.es 
Request: Send a blank email to general-es+get-41566@lists.php.net to get a copy of this message
M> Estoy intentando centrar un table mediante CSS, no me interesa hacerlo fuera M> de un *.css. He probado poner BODY{TEXT-ALIGN:CENTER;}, pero solo funciona M> en IE, en Mozilla solo centra el texto y el table aparece a la izquierda. <html> <body> <head> <style type="text/css" media="screen"> <!-- body { color: white; background-color: #003; margin: 0px } #centrando { color: white; background-color: transparent; text-align: center; position: absolute; top: 50%; left: 0px; width: 100%; height: 1px; overflow: visible; visibility: visible; display: block } #content { font-family: Verdana, Geneva, Arial, sans-serif; background-color: transparent; margin-left: -385px; position: absolute; top: -260px; left: 50%; width: 766px; height: 504px; visibility: visible } .bodytext { font-size: 14px } --> </style> </head> <body> <div id="centrando"> <div id="content"> <div class="bodytext"> <table width="100%" height="100%" align="center" bgcolor="#000000"> <tr> <td align="center" valign="middle" bgcolor="#000000"> ----------- CONTENIDO ---------------- </td> </tr> </TABLE> </div> </div> </div> </BODY> </HTML> -- Saludos,

« previous php.general.es (#41566) next »