shadow on text css code example

Example 1: text shadow

text-shadow: 0px 2px 2px rgba(0, 0, 0, 0.4);

Example 2: text shadow effect

//offset 2px right and down with a 5px defusion of gray
h1 {
  text-shadow: 2px 2px 5px gray;
}

Example 3: text shadow css

.myClass{
  /*           x   y   blur color */
  text-shadow: 1px 1px 0px #ff0000;
}

Example 4: text shadow css

background: #354962;
color: #FFFFFF;
font-family: 'Paytone One';
text-shadow: #2A3D4E 1px 1px,#2A3D4E -0px 0px,#2A3D4E -1px 1px,#2A3D4E -2px 2px,#2A3D4E -3px 3px,#2A3D4E -4px 4px,#2A3D4E -5px 5px,#2A3D4E -6px 6px,#2A3D4E -7px 7px,#2A3D4E -8px 8px,#2A3D4E -9px 9px;
/* just copy this */

Example 5: change text shadow javascript

document.getElementById("id").style.textShadow = "new";

Example 6: text-shadow

text-shadow: h-shadow v-shadow blur-radius color|none|initial|inherit;

Tags:

Misc Example