I'm really trying to move from layout tables and cells into CSS. It's a lot to take on board as a concept; tables are are good 'waterwings' and visually easier to work with. Some advice already has really helped but overall it's back to square one and I'm getting my head around code, etc: and I have two questions:
1. With "draw table/ cells" it was easier to center the site and make the pages autofit to a browsers' size (sorry if that's sloppy). How do I achieve this in CSS?
2. Again, using tables and cells; I could "draw" a "layout table" and then a "layout cell" and easily change the layout cell's backgound in the properties panel. Building CSS I cannot use the "draw layout cell", so how can I create a similar code to create a a different color behind my text or images as in what would have been a layout cell?
Apols if this may be basic and I'm overlooking something, but I've put off really moving into CSS for too long...
1. to center a page with CSS you need 3 things:
a) a valid HTML or XHTML document type (DW does this for you when you create a new page),.
b) a container width in px, em or %,
c) margin-left and margin-right of AUTO (browser defined).
See live demo (view page source to see the code)
These on-line tutorials may help to you:
From Tables to CSS Web Design Part 1 -
From Tables to CSS Web Design Part 2 -
Thanks Nancy, that's pointed me in the right direction.