c.w. wrote:If you do it yourself using position: absolute; you'll get better code, but it's not exactly an efficient way to do it.
Mmm, I agree. It does work a lot better, but it's not really that great if you're trying to be "friendly" to people with lower resolutions.
------
(Sorry if this all seems like really basic stuff...)
Straight in the HTML:
Code: Select all
<div style="width: #; height: #; background-image: url(http://);">
Content here
</div>
For use in a stylesheet/header style info.
This would be applied to all
undefined divs on your page.
Code: Select all
div {
width: #;
height: #;
background-image: url(http://);
}
Divs with a defined class:
Code: Select all
div.one {
width: #;
height: #;
background-image: url(http://);
}
-----
How to use in HTML:
<div class="one">
Stuff goes here
</div>
As far as sites go:
http://w3schools.com/css/css_background.asp
I think most of w3school's site is pretty helpful.