Posted By

jatkins on 05/17/10


Tagged

css html shadow


Versions (?)

CSS 2 Shadow Effect


 / Published in: CSS
 

Licensed under CC-by-2.0.

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  5. <title>CSS Shadow Effect</title>
  6. <style type="text/css">
  7. <!--
  8. div.shadow, p.shadow {
  9. width: 100px;
  10. height: 100px;
  11. background: #d3d3d3;
  12. margin: 10px 14px;
  13. border: 0.75em solid #d3d3d3;
  14. float: left;
  15. }
  16.  
  17. p.shadow {
  18. background: #ffffff;
  19. margin: -25px;
  20. border: 1px solid #d3d3d3;
  21. padding: 0.75em;
  22. }
  23. -->
  24. </style>
  25. </head>
  26. <body>
  27. <div>
  28. <h1>CSS Shadow Effect</h1>
  29. <div class="shadow"><p class="shadow">Test</p></div>
  30. <div class="shadow"><p class="shadow">Test</p></div>
  31. <div class="shadow"><p class="shadow">Test</p></div>
  32. <div class="shadow"><p class="shadow">Test</p></div>
  33. </div>
  34. </body>
  35. </html>

Report this snippet  

You need to login to post a comment.