MasterRacker
New member
Conditions: External style sheet, table cannot be nested in another table. I would like to define a class of table that stays centered in the browser window and has a fixed width.
Style sheet has:
[tt]
TABLE.stdtable{
WIDTH:800
}
[/tt]
HTML Page ideally has:
[tt]
<body>
<table class=stdtable>
...
</table>
</body>
[/tt]
Using <table class-stdtable align=center> does exactly what I want but leaves me with page level calls instead of a single site-wide modification point.
I've been looking at and elsewhere. I've tried margin-left:auto margin-right:auto and I've also tried float:center without luck.
From what I've seen the CSS2 spec dowsn't seem to provide for this directly. The only work-around I can think of is an external JaveScript funtion that writes the HTML code and gives me a single point of modification. That adds an extra layer of indirection that shouldn't need to be there though. Any other suggestions?
Jeff
I haven't lost my mind - I know it's backed up on tape somewhere ....
Style sheet has:
[tt]
TABLE.stdtable{
WIDTH:800
}
[/tt]
HTML Page ideally has:
[tt]
<body>
<table class=stdtable>
...
</table>
</body>
[/tt]
Using <table class-stdtable align=center> does exactly what I want but leaves me with page level calls instead of a single site-wide modification point.
I've been looking at and elsewhere. I've tried margin-left:auto margin-right:auto and I've also tried float:center without luck.
From what I've seen the CSS2 spec dowsn't seem to provide for this directly. The only work-around I can think of is an external JaveScript funtion that writes the HTML code and gives me a single point of modification. That adds an extra layer of indirection that shouldn't need to be there though. Any other suggestions?
Jeff
I haven't lost my mind - I know it's backed up on tape somewhere ....