View Full Version : Percents vs. Set Pixels

02-13-2008, 06:48 AM
Ok so this may seem rather beginner-ish but when setting the size of photoshoped sliced images on a web page I want to use percents not set pixels right? This will avoid a scroll bar on different sized pages provided it adds up to 100% right?

Andrew Johnson
02-13-2008, 09:32 AM
Pixels tend to be used for things that need to be a set size (E.G. a banner) while percents tend to be used for things like content divs where they need to be more dynamic.

02-13-2008, 10:41 AM
What are you assigning percentages/pixels to? Is it the image itself, or the container?

Images themselves should be assigned their natural pixel measures otherwise they will scale and possibly distort the image. You can place a pixel-specified image into a percentage-specified container as a background with appropriate background-positioning or overflow to control its appearance.


02-14-2008, 12:44 AM
My layout, like you cut up photoshop images and piece them together to make the layout. I guess I may not even be doing this right. Like you make different pieces of the layout in photoshop and save parts of it and then insert those images in. I guess my question is answered though.