Mon, 2004-04-12 14:33
Hi,
What I would like to do is pretty easy using tables, but I can't manage to do it right using css. Here's the 'table' code :
<table width="600" bgcolor="red"> <tr> <td align='left' width="300">Some text</td> <td align='right'>Some other text</td> </tr> </table>
Notice the different alignments for the two texts. I'm new to CSS so maybe that's a dumb question, sorry about that
David
Mon, 2004-04-12 16:10
#1
Different alignment on the same row
I hope this helps:
<!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=iso-8859-1"> <title>Untitled Document</title> <style type="text/css"> <!-- #header_container { margin: 5px; padding: 0px; left: 0px; top: 0px; } #header_left { background-color: #00FF00; float: left; height: 100px; width: 50%; } #header_right { background-color: #993300; float: right; height: 100px; width: 50%; } --> </style> </head> <body> <div id="header_container"> <div id="header_left">Content for id "header_left" Goes Here</div> <div id="header_right">Content for id "header_right" Goes Here</div> </div> </body> </html>
Mon, 2004-04-12 18:20
#2
Different alignment on the same row
Thanks !!
Just added the line in bold :
#header_right { background-color: #993300; float: right; [b]text-align: right;[/b] height: 100px; width: 50%; }
Thanks again Excavator, you rock
Edit : well, the line supposed to be bold lol