Log in

View Full Version : Apply a gradient to a box-shadow?



Schattenmann
07-14-2011, 10:23 AM
Hi,

I read Dynamic Drive articles about CSS3 gradient colors and box-shadow.

I was wondering: is it possible and if yes, how, to apply a gradient to a box-shadow?

eg: the gradient box-shadow would go from solid black to solid white
or, the gradient box-shadow would go from solid black to almost transparent

Pure CSS if possible, I would like to avoid using JavaScript.

Thanks,
Larry

deathbycheese
07-14-2011, 08:39 PM
The "gradient" effect will depend upon your box-shadow settings. Also note, it's CSS3.

Here's a good article for you:
http://www.css3.info/preview/box-shadow/

dbc