newb webpage question - best option for an idea

Soldato
Joined
20 Oct 2002
Posts
6,212
Location
UK
basically i have to create a 10 page website, using a CSS to make things easier.. how do i set it so that the main content of the site appears centre aligned on all resolutions with all browsers ? i've heard that tables are just messy ?

im using dreamweaver MX2004, trying to keep my pages xhtml scrict

using my sisters site as an example: http://www.beespokecards.co.uk/

the content isnt in the centre on my resolution 1280x1024, but is on hers 1024x768

whats my best option ?
 
sara said:
Being a bit more specific:

Just inside your HTML <body> tags, add <div class="container"></div>, and put all of your content inside that div.

Then in your CSS file, add the following (change width to preference):

.container {
width: 600px;
margin: 0 auto;
}

That should give you a centred page, 600 pixels wide.

am i right in saying that the div groups all objects.. so then the CSS will centre all included in the tag.. fantastic thankyou :)

why not use my sisters site as an example, shes only 14 !
 
Back
Top Bottom