View Single Post
Old 08-04-2012, 05:10 AM   #1
44reader
Connoisseur
44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese44reader can extract oil from cheese
 
44reader's Avatar
 
Posts: 61
Karma: 1234
Join Date: Jun 2012
Device: none
How do you center text vertically?

How do you center text on a page, like in the attached image?

I am a complete novice at html but I guess it would involve tags like this:

<p class="P-P5">MY CENTERED TEXT</p>

and then setting top and bottom margins in the stylesheet.

Here is an entry from my current stylesheet. Can you tell me how to adjust it to get the text centred vertically as well as horizontally please?

P-P5 {
border-bottom: 0;
border-top: 0;
display: block;
font-family: "Times New Roman", serif;
font-size: 1.83333em;
font-weight: bold;
line-height: 1.2;
margin-bottom: 0;
margin-left: 0;
margin-right: 0;
margin-top: 0;
padding-bottom: 0;
padding-left: 0;
padding-right: 0;
padding-top: 0;
text-align: center
}
Attached Thumbnails
Click image for larger version

Name:	center.png
Views:	354
Size:	9.3 KB
ID:	90157  
44reader is offline   Reply With Quote