As of CSS3, an easy way of stretching background images has been added. This can be used to make sure that your background images inside your containers (either of div or table) can be resized properly.
background-size: 100% auto; -moz-background-size: 100% auto; /* for lower versions of Firefox */ -o-background-size: 100% auto; /* for lower versions of Opera */ -webkit-background-size: 100% auto; /* for lower versions of IE and Chrome */
The code above will work on the following:
- Safari 3+
- Chrome Whatever+
- IE 9+
- Opera 10+ (Opera 9.5 supported background-size but not the keywords)
- Firefox 3.6+ (Firefox 4 supports non-vendor prefixed version)
Unfortunately, opera mini doesn't support this.