CSS Tutorials: Shorthand CSS Guide PDF

Posted on Tuesday 10th May 2011 by Luci Smethurst 4 Comments

Every web designer should have a collection of guides (well, I think they should anyway) for those days when your mind goes blank and you cannot for the life of you remember how to give something a border (hey, it’s happened) in a web design you’re coding up.

Download our Short Hand CSS Guide Well, today I’ve got a little present for you. A downloadable pdf that has the most common css elements and their shorthands for you. It’s got cute little animals as well, so you can stick it on your wall, or on your desk, and have something nice to look at, at the same time!

For those of you that don’t like downloading, or are perhaps unable to do so at this time, here’s a summary:

background: color image-url repeat position attachment
list-style: type position image
font: style variant weight size/line-height font-family
outline: width style color
margin: top right bottom left
padding:  top right bottom left

With regards to the margin and padding elements, the motion of top right bottom left can apply to all box-style elements, for example borders. You can also shorten them further if you only need to apply one size to all, so

padding: 10px;
margin: 5px

would apply 10px padding and 5px margin to all sides of an element. If you wanted to have different amounts for your vertical and horizontal, you could shorten it like so:

padding: 10px 0;
margin: 5px 15px

This would apply 10px of padding and 5px margin to the top and bottom and 0 padding, with a 15px margin to the left and right.

Thanks for reading our web design blog this week, don’t forget to check back on Friday for James’ video blog!

About Luci Smethurst

Luci likes geeky things, green things, and chocolate. That pretty much sums her up, really.

See all of posts.

Add on Luci Smethurst Google+

Luci Smethurst's Tweet's

  • @missrachilli hold out! you can do it -strepsil it up! Go by the 3 day rule - day 1: bad; day 2: awful; day 3: (a bit) better :) Less than 1 minute ago!
  • RT @daniel_c_long: Cool Photoshop action to remove gradient banding http://t.co/XQ2lUZoj via @brdrck Less than 1 minute ago!
This entry was posted in HTML & CSS Tutorials and tagged , . Bookmark the permalink.

4 Responses to CSS Tutorials: Shorthand CSS Guide PDF

  1. Ian says:
    May 15, 2011 at 10:40 pm

    Great article about CSS…… I have downloaded and have found this very useful!!

  2. andaru says:
    June 27, 2011 at 2:33 am

    very useful for newbie like me, thank you very much

  3. Alan Richter says:
    July 27, 2011 at 8:15 am

    Cheers Lucy, you babe!

  4. vishal bandre says:
    September 6, 2011 at 3:58 am

    Above problem worked after refresh of page. Admin please delete comment above

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>