< CSS Box Shadow />

0
(0)
box-shadow: 10px 5px 5px red; 

This is an example box, with a red shadow.

The box shadow property in CSS adds a shadow to any element in HTML. A box shadow is described by X and Y offsets relative to the element, blur and spread radius, and color.

/* offset-x | offset-y | blur-radius | color */
box-shadow: 10px 5px 5px black;

/* inset | offset-x | offset-y | color */
box-shadow: inset 5em 1em gold; 

If a border-radius is specified on the element, the box-shadow will take the same rounded corners as the element.
If used multiple box-shadow‘s, the first one will be on top.

box-shadow: 3px 3px red, -1em 0 .4em blue; 

This is a box with multiple box-shadows around it.

Did this help you?

Average rating 0 / 5. Vote count: 0

As you found this post useful...

Follow us on social media!

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

Share on facebook
Facebook
Share on twitter
Twitter
Share on linkedin
LinkedIn
Share on telegram
Telegram
Share on whatsapp
WhatsApp
Share on print
Print

Did this help you?

Average rating 0 / 5. Vote count: 0

As you found this post useful...

Follow us on social media!

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

Justin van lier

Justin van lier

I am a self taught Software Engineer with experience in managing and developing game servers, websites, applications & backend systems. I began to work on a professional level since April, 2014. I'm always excited to teach people about Computer Science and the advantages that come along.