Krossbrauzernoe alignment on the center
From time to time me ask how to force to work the following code in Opera 7.0, and also in Internet Explorer 6 and Mozilla, when page in mode Standards compliance mode:
<table width = " 100 % " height = " 100 % ">
<tr>
<td align = "center"> the text which should settle down in the center of page </td>
</tr>
</table>
Why the text turns out prizhatym to the top border of the document instead of settling down in the center? First of all the matter is that in specification HTML 4.01 at tega table there is no attribute height, and consequently browsers in a mode of compatibility with standards (and Opera 7.0 in any case) ignore it{him}. But the most interesting, that they cease to ignore it{him} if in CSS to specify the following design for extension of an outline of the document:
html, body {
height:100 %;
margin:0px;
padding:0px
}
Actually, you do not need to change something in itself HTML a code in which at you it is registered (perhaps for a long time when you and did not think, that height can sometime "cancel") height of the table.
Expecting questions, I want to make a pair of remarks under the resulted style description.
First, it is necessary to specify both elements html and body as it is simple body insufficiently. For example, for Mozilla in Standards compliance mode an outline is the element html, instead of body.
Second, if to clean{remove} zeroing margin and padding besides in a mode of compatibility with standards at page the unpleasant vertical strip of scrolling will appear.
Well and at last I want to note, that in any case the document in which contains teg table with attribute height, will not pass check. If to you will heat I oppress consciousness of that your documents valid, I advise to replace this attribute on CSS property height, not having forgotten, nevertheless, to specify in the table of styles the above mentioned decision for extension of an outline.

|