Activate your free membership today | Log-in

Friday, March 6th, 2009

CSS3 Fun Tests and Hackz

Category: CSS, Standards

>What would you get if you have a sample that used the following CSS3 features:

This, if you are viewing in FF3.1+:

All via:

HTML:
  1.  
  2. <style type="text/css" media="screen">
  3.         @font-face {
  4.         font-family: Delicious;
  5.         src: url('http://blog.mozilla.com/webdev/files/2009/02/delicious-roman.otf');
  6.     }
  7.    #css3test {
  8.                width: 350px;
  9.                margin: 0 auto;
  10.                background: #000;
  11.                padding: 20px;
  12.                color: #fff;
  13.                text-align:left;
  14.                -moz-border-radius: 10px;
  15.                text-shadow: 0 0 4px white, 0 -5px 4px #FFFF33, 2px -10px 6px #FFDD33, -2px -15px 11px #FF8800, 2px -25px 18px #FF2200;
  16.                -moz-box-shadow: 10px 10px 5px #888;
  17.            -moz-column-count: 3;
  18.            -moz-column-gap: 1em;
  19.            -moz-column-rule: 1px solid white;
  20.            font-family: Delicious, sans-serif;
  21.            font-size:127% !important;
  22.            border: 8px solid #000;
  23.            -moz-border-bottom-colors:#CC0000 #BB0000 #AA0000 #990000 #880000 #770000 #660000 #550000;
  24.            -moz-border-left-colors:#CC0000 #BB0000 #AA0000 #990000 #880000 #770000 #660000 #550000;
  25.            -moz-border-right-colors:#CC0000 #BB0000 #AA0000 #990000 #880000 #770000 #660000 #550000;
  26.            -moz-border-top-colors:#CC0000 #BB0000 #AA0000 #990000 #880000 #770000 #660000 #550000;
  27.            }
  28.         </style>
  29.  
  30. <div id="css3test">
  31. <p>This is a CSS3 awesome test. It demonstrates some of the awesome parts of CSS3 implemented in Firefox 3.1.</p>
  32. </div>
  33.  

Also, Daniel Glazman had a fun thought and discusses a technique that could get:

CSS:
  1.  
  2. @if-implemented { display: table-cell}
  3.    p { background-color: green; color: yellow}
  4. @else-implemented;
  5.    p {background-color: red}
  6. @endif-implemented;
  7.  p { font-size: large}
  8.  

Related Content:

Posted by Dion Almaer at 6:59 am
Comment here

+++--
3 rating from 2 votes

Comments Here »

Comments feed TrackBack URI

Leave a comment

You must be logged in to post a comment.