Posted by John on 10/23/06 13:52
Hi
I have an HTML image whichwill stretch the width of the screen. No
problems.
<img src="castle.jpg" width="100%">
However, I now want to make it a background image using CSS. There is no
'width' attribute for a background image.
The following does not work.
body.blueberry {background-image: url(castle.jpg);
background-attachment: fixed; background-position: bottom center;
background-repeat: no-repeat;}
img.blueberry {width:100%}
Is there anyway of stretching the background image as in the HTML img
construct?
Regards
John
Navigation:
[Reply to this message]
|