If i have a header image that is 500px wide what css property do i need to use so that the image fills & fits in the header no matter what the screen resolution is ?
What's the height? Let's suppose it's 500px.
header {
background: url(images/header.gif) no-repeat;
width: 500px;
height: 500px;
}
Something like this should work just fine.
But if the header is bigger or smaller will it fit not matter the width of the image ?
I want the image to stretch and fit in the header no matter what the image width is.
Sure, remove "width: 500px" and it should work. Just play with it.
Ok thanks
If the image is say 200 px wide, you could tile it using repeat-x as there is no way to stretch an image using CSS to my knowledge.
OR
You could use HTML
<img src="img url" width="500px"> which will stretch the image.
(2010-06-11, 11:27 PM)Lyndon Dueck Wrote: [ -> ]You could use HTML
<img src="img url" width="500px"> which will stretch the image.
That is what i would use if i wanted to stretch it... That is probably the safer option.