Click to See Complete Forum and Search --> : How do I center a frameset?


jtelep
12-16-2005, 03:44 PM
I have been working on designing pages that are no more than 800 pixels wide to support users who are running lower resolutions. My main page is a frameset broken into 3 columns totally 800 pixels. What I would like to know how to do is this: If someone is running a resolution of more than 800 pixels wide (i.e. 800x600) like 1024x768 or greater, how can I get my entire frameset to appear centered instead of always appearing left justified (thus messing up my formatting inside the frames)? Perhaps a centered frameset with a different background/background color so they know where the border of the frameset is? I have seen this done on many different websites and would really like to know how to do this myself.

Thanks in advance!

tgrk35
12-16-2005, 04:28 PM
Several things:

1. 800px wide is too wide for users with 800x600 resolutions (most times). I would use 760px max.

2. I wouldn't use frames. Frames are depreciated. Use divs or even tables would work (although the lesser solution).

3. Use a container div to center your entire "site." <div class="container">STUFF</div> (in your css, then do --> .container{margin: 0px auto;}

Anything else?