I have posted about double borders with CSS before but there was a useful tip by Andy Hume (@andyhume) at a recent London Web Standards meeting where he described the use of CSS3 box-shadow (previously on this blog, Box Shadow and Image Hover Effects) to give the effect of double borders on an element. With box-shadow, if you use zero for the horizontal offset and blur radius values and a small pixel value for vertical offset, this will give you another ‘border’ on any element. If the element already has a border, this means that you can create double borders with different colors. Here’s how it works.
Truth be told, I don’t really know if CSS3 gradients are the next big thing or not but, with increasing support in modern browsers, they are being used more and more. Like many other CSS3 properties, gradients allow us to create image-like properties with a few lines of code, thus saving on image requests, and make it easy to change backgrounds quickly and easily without using Photoshop or Fireworks.
I was browsing a few websites the other day when I came across Stunning CSS3 which promotes a forthcoming book by Zoe Mickley Gillenwater. There are lots of CSS3 properties used on the site but one that caught my eye was the circular ‘Fall 2010’ item near the top of the page. Here, the border-radius property is used to create the circular shape. I have only used border-radius with small radii values before now but larger values allow you to make a circle.
Drop caps are a nice typographic detail that look great on many websites; I’ve used these myself on several examples including Just Holiday Nannies (main page headings) and Occupational Synergy (leading paragraphs). There are a few ways of achieving this effect but the CSS selector I like to use is the :first-letter pseudo-element. This selector is reasonably well supported across most modern browsers (albeit with a few minor bugs here and there). Here’s how it works.
I like to browse a lot of websites with the aim of learning from how others do things. I figure that this is part of my job as a freelance web designer/developer. However, sometimes it is difficult to know what went on during the design process of any website you look at. That’s why I particularly like blog posts, articles, and other case studies, where a website design is explained. Normally, this will deconstruct the website in question and I find these really useful. Here are a few case study ‘design stories’ that I have been reading recently:
All these chaps are talented designers and more than likely they will also do things differently to you. It makes sense to try and learn from them….
CSS Mastery: The second edition of this famous book by Andy Budd contains new examples and updated browser support information, new case studies from Simon Collison and Cameron Moll, and new CSS3 methods.
Buy from Amazon.com · Amazon.co.uk
Join SugarSync for online backup. Sync your files between Mac, PC and mobile phone. Get 2 GB FREE and up to 10 GB bonus space!