vertically center a page regardless the resolution HELP PLEASE!!!!

liunx

Guest
Hello, i have a little problem...<br />
<br />
i have a frame witha table tha has an image and some text, what i need is a way of centering vertically the table regardless the resolution that the user is using, that is the table must be centered if a user is using 800x600 or 1024x768..is there anyway of coding this like with javascript?<br />
<br />
<br />
thanx<br />
Kokas<!--content-->I might not understand your question but couldn't you just make another 1 row by 1 column table that has 100% width and the TD is aligned center?<br />
<br />
IE:<br />
<table border="1" cellpadding="0" cellspacing="2" width="100%"><br />
<tr><br />
<td align="center">blahblah blahblah</td><br />
</tr><br />
</table><br />
<br />
That might not be what you want or need though.<!--content-->that centers the cell horizontaly not vertically the entire page<!--content-->If you are just using a table with a single cell for your text and image you can set the height of the table to 100% which by default will centre the cell contents vertically.<br />
<br />
<table border="1" cellpadding="0" cellspacing="2" height="100%"><br />
<tr><br />
<td align="center">blah blah blah blah</td><br />
</tr><br />
</table><!--content-->
 
Back
Top