View Full Version : img src change wit css???


the_dark_one02
03-22-2003, 06:24 PM
is there a way to change an image soucre in a css? coz i use a style switcher to change the colour n i wanted to change a couple of pictues, so is it possible????

please and thanks if u help me :D

epolady
03-22-2003, 06:42 PM
You can set it like so:

#somename{
background-image: url(imagename.gif);
height: ###px;
width: ###px;
other css here
}

and in your pages

<div id="somename"></div>

the_dark_one02
03-22-2003, 06:43 PM
by the way wats a DIV is it a layer or something?

do i hav to use a div cos im also usin an image preloder that wont work wit background images

epolady
03-22-2003, 07:41 PM
Basically a div is a block to where you put information and style/postion it etc.

I'm not sure which is the best way to do it as I've never skinned my site.

the_dark_one02
03-22-2003, 08:32 PM
oh well thanks anyway ill hav a little play wround to cee wat i can do thax again