Can CSS be set to display at 100 percent?

Status
Not open for further replies.

WallaceCleaver

New member
Jun 26, 2006
598
0
0
My computer chair
Has anyone figured out a way to use CSS to display at 100%? You know how with tables you can set it to 100% and no matter what size screen the person is using it fits. I was using a Wordpress templates that is CSS-based and the size is set in pixals. I tried just typing in 100% percent, but no joy.
 


This should definitely be possible. The default Wordpress template should scale to 100%.
 
css can do % as well. Check to make sure there arent any width settings below the one you set to 100% setting it back.
 
a.titus1 said:
css can do % as well. Check to make sure there arent any width settings below the one you set to 100% setting it back.

So, if I had pixal settings below the % one it would just override it? Hmm, okay, I'll have to give it another go and set them all to 100%. I didn't even think of that that it would override the setting.
 
WallaceCleaver said:
So, if I had pixal settings below the % one it would just override it? Hmm, okay, I'll have to give it another go and set them all to 100%. I didn't even think of that that it would override the setting.

It is absolutely possible. Maybe there was an outer container or something that was preventing the change you tried. Also, you need to make sure all the specific pieces that you wish to have fluid are edited. Or, maybe you gave the container 100% but the inner containers were still set to fixed widths. There's multiple reasons the chang emay not haveworked so check everything out.
 
starting a full-width layout:
* {margin:0;padding:0;} /*Resetting all browser spacing, including the default spacing on the body tag that would mess up your 100% layout*/

container {width:100%;}

keep in mind that you can't give padding and margin to your 100% width boxes, because the spacing will add up to the 100%.
 
Also, don't forget that width is inherited by child elements, if your container is set to 900px wide and you put a 50% width column inside it, the column will be 450px wide.
 
Status
Not open for further replies.