What good css quotes can you come up with?

some that I can think of

font: bold 20px Verdana, sans-serif / * one line for variant, size and family * /

color: # 336 / * short color code * /

height: 0 / * no need to specify unit if 0 * /

border: 0 / * same effect as border: no, but shorter * /

background: # ffc / * don't need to use background color if everything needs color * /

padding: 0; border: 0; margin: 0 / * to show only content but nothing else * /

border: 1px dotted # ff0 / * thickness, style and color * /

margin: 0 0.5em / * specify top, bottom, left, right margin * /

0


a source to share


3 answers


 1. background: #fff url(image.png) no-repeat 20px 100px fixed;
 2. ul { list-style: decimal-leading-zero inside; }

      

Comma delimited declarations

  • h1, h2, h3, h4, h5, h6 {font-family: Helvetica, Verdana, sans-serif; }

First parent selectors

 1. .footer em:first-child { color:#ccc; }

      



CSS3 functions

Rounded box with radius

  • .rounded_corner { -moz-border-radius:10px; -webkit-border-radius:10px; width:400px; height:100px; background-color:#000; }

Shadow effect

.shadow {width: 400px; height: 200px; background color: # 000; -webkit-box-shadow: 5px 5px 2px #ccc; }

+2


a source


You can also specify the line height using the font property

font: bold 20px/1em Verdana, sans-serif /* one line for variant, size, and family */

      



Where 1em is the line height

0


a source


Describe another one:

outline:3px dotted gray;

      

List style supports images:

list-style:square inside url(image.gif);

      

Kind of redundant, but here's another article explaining them all:

http://www.456bereastreet.com/archive/200502/efficient_css_with_shorthand_properties/

0


a source







All Articles