How can I center a page with Dreamweaver CS3 using an AP div tag?

How can I most simply center a page with Dreamweaver CS3, preferably using an AP Div Tag container?
Using text align center and margin 0 auto as some suggested didn't seem to do the trick.
I'd prefer to be able to do this using the CSS panel but not actually inserting code.
The only way I can do it is by using a table but I want to start designing sites with AP elements and CSS instead of relying on tables.
Thanks.
LPNavonAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
paulp75Connect With a Mentor Commented:
<div style="text-align:center; margin-left:auto; margin-right:auto;">
<div>this one should be centered now</div>

</div>
0
 
chilternPCConnect With a Mentor Commented:
for css anddreamweaver see:

http://livedocs.adobe.com/en_US/Dreamweaver/9.0/help.html?content=WScbb6b82af5544594822510a94ae8d65-7e13.html

but there's nothing wrong with centreing a table with no border and writgin inside it.

<table align="center" border="0">
<tr><td>
blah blah content
</td></tr>
</table>

0
 
Jason C. LevineConnect With a Mentor No oneCommented:
You can't center an AP tag...absolute position means absolute.

So you can use either chiltern's or paul's method to center a relative div...

>> but there's nothing wrong with centreing a table with no border and writgin inside it.

Not totally true (the nothing wrong part), but that's a different discussion.
0
The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

 
LPNavonAuthor Commented:
If you can't center AP div tags, it would seem AP divs are useless for creating pages with centered layouts, which I find rather disappointing.
Presumably I can't even really nest an AP tag in a centered relative Div tag. Perhaps I'll just have to resort to using tables again. I presume laying out a centered table but converting it to AP divs will also not work.



0
 
chilternPCCommented:
yep - AP are all about absolute positiions - so looking on different size screens/different resoltions itwould shift about - use regular CSS for centring or.....
the good old table method has the advantage of working    
...and on all browsers (IE,safari,firefox,netscape
But try the following CSS site
http://maxdesign.com.au/presentation/page_layouts/
in particular:
http://maxdesign.com.au/presentation/page_layouts/single02.htm
0
 
LPNavonAuthor Commented:
Thanks for this Chiltern
Are tables actually more reliable in terms of browser universality than relative divs and CSS, which I thought I should be aiming for?
The MaxDesign site loos pretty cool...
Larry
0
 
chilternPCCommented:
certain CSS things don't work with IE  (usually the ones I've implemented)
I think now the market is 20% firefox, 15% (and rising) safari and 60% IE and the rest odds and sods.
tables do work but are clunky and slow if large as the page has to load the entire table before it shows
but do CSS until you hit a problem and work backwards to tables. :-)
0
 
Jason C. LevineNo oneCommented:
There is very little you cannot do with CSS that would force you to revert to a table for layout.
0
All Courses

From novice to tech pro — start learning today.