-
I can't figure out how to place a table in the middle of a browser. Centering horizontally is easy enough, but I need the table to be centered vertically too.
I want this to work regardless or browser, resolution, and size of browser window.
Thanks in advance.
-
Hi N*G*Evangelion
use an outer table to place the table you want to centralise.
Code:
<html>
<head>
</head>
<body bgcolor="#FFFFFF">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" height="100%">
<tr align="center" valign="middle">
<td>
<table width="50%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
Hope this helps
Ian
-
Thanks for the reply.
I did try to use that method previously, but Netscape doesn't support the height attribute of the table tag - so it doesn't work - even in NS6.
If anyone has another way that is browser independent then please post your reply.
Thanks again.
-
I tried that page in NS before I posted and it worked fine.