Forum How do I...?

Aligning text in headers

howellgg
Hi,

Sorry for a real noob question, but I am ;-)

I have tried everything I can think of to align my text in the headers, but I just don't seem to be able to. I finally gave up on my main page, and have been trying to do it with even a little test page (see below) with no luck.

Help!

Thanks,
Grant

------------

<HTML><HEAD><title>My Test</title>
<style>
@page {
size: US-Letter;
margin: 60pt 40pt 60pt 40pt;
@top-left-corner {
content: flow(hdr01);
text-align: left;}
@top-left {
content: flow(hdr02);
text-align: left;}
@top-center {
content: flow(hdr03);
text-align: center;}
@top-right {
content: flow(hdr04);
text-align: right;}
@top-right-corner {
content: flow(hdr05);
text-align: right;}
}

#hdr01 { flow: static(hdr01);}
#hdr02 { flow: static(hdr02);}
#hdr03 { flow: static(hdr03);}
#hdr04 { flow: static(hdr04);}
#hdr05 { flow: static(hdr05);}
.hdr01 { text-align: "left";}
.hdr02 { text-align: "left";}
.hdr03 { text-align: "center";}
.hdr04 { text-align: "right";}
.hdr05 { text-align: "right";}
</style>
</HEAD>
<BODY>
<SPAN><DIV>ulc</DIV></SPAN>
<SPAN><DIV>upper-left</DIV></SPAN>
<SPAN><DIV>upper-center</DIV></SPAN>
<SPAN><DIV>upper-right</DIV></SPAN>
<SPAN><DIV>urc</DIV></SPAN>
<p>
This is my test
</p>
</BODY>
</HTML>
mikeday
Can you repost your test and click "Disable HTML in this post" at the bottom of the post form, so that it doesn't throw away the attributes? Sorry about that! :)
howellgg
Hi,

Thanks for the quick reply. Here's the code again:

<HTML><HEAD><title>My Test</title>
<style type="text/css">
@page {
size: US-Letter;
margin: 60pt 40pt 60pt 40pt;
@top-left-corner {
content: flow(hdr01);
text-align: left;}
@top-left {
content: flow(hdr02);
text-align: left;}
@top-center {
content: flow(hdr03);
text-align: center;}
@top-right {
content: flow(hdr04);
text-align: right;}
@top-right-corner {
content: flow(hdr05);
text-align: right;}
}

#hdr01 { flow: static(hdr01);}
#hdr02 { flow: static(hdr02);}
#hdr03 { flow: static(hdr03);}
#hdr04 { flow: static(hdr04);}
#hdr05 { flow: static(hdr05);}
.hdr01 { text-align: "left";}
.hdr02 { text-align: "left";}
.hdr03 { text-align: "center";}
.hdr04 { text-align: "right";}
.hdr05 { text-align: "right";}
</style>
</HEAD>
<BODY>
<SPAN id=hdr01 class=hdr01><DIV class=hdr01>ulc</DIV></SPAN>
<SPAN id=hdr02 class=hdr01><DIV class=hdr01>upper-left</DIV></SPAN>
<SPAN id=hdr03 class=hdr03><DIV class=hdr03>upper-center</DIV></SPAN>
<SPAN id=hdr04 class=hdr04><DIV class=hdr04>upper-right</DIV></SPAN>
<SPAN id=hdr05 class=hdr05><DIV class=hdr05>urc</DIV></SPAN>
<p>
This is my test
</p>
</BODY>
</HTML>
mikeday
Oops, I didn't notice at first but it's just because the text-align values are in quotes, like strings, whereas they are supposed to be unquoted keywords, like this:
text-align: right;

If you remove the quotes it should work fine! :)
howellgg
Thanks, that did it. Boy, do I feel sheepish! :oops: