I am trying to set the width of my site and I have 2 css one is style.css and other is this one layout.css
I want to fix my site and a certin width how do I do that. I change the main wrapper but it did nothing.

/* Implentation of the "One True Layout" by positioneverything.net */
#main-wrapper {
float:left;
width:100%;
}

#main {
margin:0;
}

.withleft #main {
margin-left:190px;
}

.withright #main {
margin-right:190px;
}

#left {
float:left;
margin-left:-100%;
padding:5px 8px 20px;
width:174px;
}

#right {
float:right;
margin-left:-190px;
padding:5px 8px 20px;
width:174px;
}

* html #right {
margin-left:-190px;
}

#footer {
clear:both;
}

Comments

nevets’s picture

With just the CSS it is a bit hard to answer your question. A link to your site would make it much easier for people to try and help you.
That said, if you are trying for fixed width and '#main-wrapper' is your outer wrapper, in

#main-wrapper {
float:left;
width:100%;
}

setting width to 100% is likely to fill the browser window. Something like width:800px; might help in setting the width.

touchcrew’s picture

nevets’s picture

If you use firefox I would suggest loading the firebug extension which is real useful for exploring the layout of a page.

If you are trying to control the width of the whole page you need to pick a different element than '#main-wrapper' which only applies to the central content. To control the width of the whole page I would try using '#page', something like this

#page {
  position: relative;
  width: 850px;
}

The "position: relative;" is need to keep the primary navigation on top of the header (otherwwise it stays on the right side of the page)