Positioning a square shaped table in the middle of the screen

admin

Administrator
Staff member
I am trying to center a square shaped table in the middle of the screen. I want the table to have equal amounts of white space on all sides. <br />
<br />
And yes, Im a n00bie to html :)<br />
<br />
Any ideas?<br />
<br />
Sorry - forgot to post the code.<br />
<br />
<html><br />
<br />
<head><br />
<title></title><br />
</head><br />
<br />
<body><br />
<br />
<div align="center"><br />
<center><br />
<br />
<table border="1" width="50%"><br />
<tr><br />
<td width="100%">Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
vvExample Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, </td><br />
</tr><br />
</table><br />
<br />
</center><br />
</div><br />
<br />
</body><br />
<br />
</html><!--content-->what is the code you are using?<!--content-->this should work in most browsers:<br />
<br />
<html><br />
<head><br />
<br />
</head><br />
<body><br />
<table cellspacing="0" cellpadding="0" border="0" width="50%" height="100%" align="center"><br />
<tr><br />
<td>&nbsp;</td><br />
</tr><br />
<tr><br />
<td height="50%" valign="middle" align="center" style="border: solid 1px #000000;">Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,<br />
Example Text, Example Text, Example Text, Example Text, Example Text,</td><br />
</tr><br />
<tr><br />
<td>&nbsp;</td><br />
</tr><br />
</table><br />
<br />
<br />
</body><br />
</html><br />
<br />
<br />
it is a bit weird to do it this way but maybe its all you need.<!--content-->Thank you Kevin!<br />
Worked out great.<!--content-->
 
Back
Top