The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Get main wrapper to grow with window maximize?

Hello, how do I get the main div to expand to the whole window when t is maximized? Now, it is fixed based on how much content is in the smaller div inside it. Example better explains it. Maximize the window:

Well, I want to have the wrapper expand with the window, but have a min-width of 725px to display correctly on an 800x600 monitor and still display the site correctly and have a 5px margin around the wrapper. I also want a header and a footer. I know this is easy stuff, but all the little hacks and what not are what throw me off. 95% of our users have IE6, the 3% that uses Fx is likely me and the three of us in the IT dept. I hate that things look radically different bn browsers because it is a PITA to make everyhting lok ok. This is so frustrating, I wish IE would get its "I'm going to do whatever the hell I want" mentality out of its head and comply for once. </rant> I'm going on break

Thanks. I'm trying to go through it and convert your two letter appreviations to something I can understand. There's a lot I don't understand in that code like the head+body, * html, or any ">" things. I wish I knew what each statement meant instead of just copying it from someone else.

How the site looks from when I started this thread is how I want it to look, with the exception of the main wrapper not stretching relative to the window size. Is there a way that I could just edit my existing code without re doing everything from scratch again? Also, what is the .px class for? I do appreciate the help.

I was playing around with it and renamed some things so that I can understand them. When I added borders to some things everything got all messed up. It's the fact that everything is done with EMs which isn't an absolute value so I can't just add or subtract like I'm used to with non-advanced css. It's all confusing when I goto change anything. And now if I add borders it is going to be different in IE vs. mozilla browsers. Is there a place I can read about how to correctly do this on my own without asking for help all the time?

Ohhhh, I think I see what you did, well most of it. You just moved the main div up with a negative margin and added the footer on as an additional div added onto the #main div. I never thought of doing it that way; it's very intuitive. Question: I want it so that the #content div stretches with the window also, but I want it to always have a 10px margin bn it and the footer, that way the footer doesn't run over the #content div in low res monitors or in a small window with lots of content. You sure came up with that fix real quick... Is there anything that I am doing wrong or should be doing a different way as far as css or syntax goes? Or your opinion? Constructive criticism works wonders for me Thanks.

I know my DTD is a problem. I had tryed to convert it to strict and everyhting looked right when i resized some elements except that i had about 10px hanging off the screen to the right no matter the size of the window. I spent far too long trying to figure that out. Are you saying that the original layout that you posted should be my best bet?

I created that page from scratch. Obviously my CSS needs some work. I suppose I will just have to re-code the whole thing so that it complies with the "strict" DTD. If it will help get rid of a lot of problems I am having, I will do it that way. I was just hoping that there would be an easier way for me to understand that wouldn't require elaborate negative margins and tons of divs with different margins and properties that I end up losing track of. I had the book "101 css tips and tricks" on my desk but I had to return it last week. It helped a little, but didn't address a lot of my needs.