In this article you will get access to one of the largest collections ever of CSS Tools, Tutorials, Cheat Sheets etc. It builds on previous CSS posts in tripwire magazine with the purpose of creating a one stop fit all CSS resource. Several new resources have been added.
Please comment if you know a great CSS resource that didn’t make it on the list and I will add it ASAP.
- CSS getting started and reference resources
- CSS Page Layouts
- CSS Positioning Tricks
- CSS and [Form] Elements
- CSS Typography Tricks
- CSS Data Visualization Techniques
- CSS Working with Images
- CSS and Lists
- CSS Print Page Tricks
- CSS and Tables
- CSS Grid Frameworks
- CSS Tool tips
- CSS Navigation and Menus
- CSS Editing and Code Generation Tools
- CSS Code Cleaner Tools
- CSS and HTML Cheat Sheets
Large getting started guide with everything you ever wanted to know about the basics of CSS
This guide will attempt to take you step by step, through the process of creating a fully functioning CSS layout. I will try my best to explain the concepts behind each step, but a lot of the time other people have already covered these things better than I can. Because of this there will sometimes be links to more information on external sites.
Introduces most elements of we b development, including css.
This is really essential tips from true css experts. A must read!
Apart from Floats, the CSS Specificity is one of the most difficult concepts to grasp in Cascading Stylesheets. The different weight of selectors is usually the reason why your CSS-rules don’t apply to some elements, although you think they should have. In order to minimize the time for bug hunting you need to understand, how browsers interpret your code. And to understand that, you need to have a firm understanding on how specificity works.
CSS is a relatively simple language to learn. Mastering it, on the other, can prove a little more difficult. Compensating for various browser inconsistencies alone can produce a migraine. In this article, we’ll demystify five of the most head thumping issues that you’ll encounter when building web applications.
Sure, anyone can write CSS. Even programs are doing it for you now. But is the CSS any good? Here are 5 tips to start improving yours… 1. Reset, 2.Alphabetize, 3. Organization, 4. Consistency, 5. Start in the right place…
Any designer who has worked with large CSS files will agree that its major weakness is its inability to use variables. In this article, we will learn how to implement variables by using PHP and Apache’s URL rewrite mod.
Making your website compatible with a wide range of browsers is probably the hardest task of a front-end developer. To make your coder life easier, here is 15+ tools and techniques for crossbrowser CSS development.
Throughout the guide, you will be shown cunning CSS techniques used to keep loadtime to a minimum and to organize and fine tune your content so it is presented in the best possible way.
This tutorial explains how to manually change a layout, and it shows two great examples and “how they did it.”
Learn how to re-create the Facebook footer admin panel with CSS and jQuery. Also check out part 2.
Here is a script to match the heights of boxes in the same container and create a tidy grid, with little overhead.
This site contains free css templates for your website – Just copy and paste and there you have a stunning website !
If 53 fixed layouts were not enough here are some more both fixed and stretched layouts for ultimate flexibility. These 40 layouts are again completely CSS styled without any tables.
42 free fixed length layouts ready for use
A quick and simple way to enable users to switch page layouts using CSS and jQuery.
A common problem among designers is how to get a div to stretch 100% of the window’s height. There are a few different techniques out there, and this tutorial shows one of them.
If you ever made a web site with the content in a center column and a different background for the body, or with a short lateral navigation bar, probably you experienced the problem of some elements not extending to the bottom of the browser window when the height of the content is lesser than the document area of the browser window.
Other than the “Turn off the lights” feature, YouTube has great stuff, such as the “change view” feature, which allows you to switch between normal and wide mode, thus expanding or shrinking the video area. Creating this is very simple.
A common pitfall of a CSS based columns layout is that the columns do not share a common height. Unlike a table based layout where the height of the table itself dictates the height of all of its columns, CSS columns are independent of one another in that respect. Now, this can be problematic (from a design standpoint) when you wish to style one of your CSS columns in a way that should extend all the way down to the end of the layout, such as giving a side column an explicit background color, a surrounding border etc…
This article discusses ways to create equal-height columns that work in all major browsers (including IE6). All of the methods show how to create a three-column layout.
How do you center a containing block on a page using CSS? There are two main methods and the choice should be made based on whether your page layout is liquid (will move in and out depending on the size of the browser window) or fixed width.
There were ways to center-align left-floated elements, but then inline-block became popular and everything changed. After a bit of tinkering, Zaharenia Atzitzikaki found an efficient and (mostly) cross-browser-compatible way to center elements without floats.
A page element with relative positioning gives you the control to absolutely position children elements inside of it. To some, this is obvious. To others, this may be one of those CSS “Ah-ha!” Moments. I remember it being a big deal for me when I first “got it”.
Here, we have a basic unordered list (ul), with left-floated images where the text doesn’t wrap under the images. Of course, this technique could be deployed in loads of other instances.
With faux absolute positioning, we can align every item to a predefined position on the grid.
Let’s see a quick tip for aligning vertically navigation lists that use the tipical floated box approach to display the list in a row, but that have several items displayed across multiples lines.
Introducing Uniform, a plugin for jQuery that lets you style select, radio, and checkboxes however you desire.
Avery user friendly way to show checkboxes.
This script is for people who wants to have a consistent look for checkboxes across browser or those who simply want them to look better. By using this script you wont loose any of the regular inputs usability.
Highlight increases usability by highlighting elements as you interact with the page. Its primary use is for forms, but it can also be used for tables, lists, or any element you specify.
This article does not cover styling of image links that is closely realted to styling of submit buttons but usually used for menu navigation.
Buttons are a very important part of a website: They’re the most common way your visitors can trigger an action and interact with your website. Sadly, even theses days many web pages still displays ugly buttons. Here’s our “Top Ten” CSS buttons tutorial list, for giving your buttons, submits and links the beauty
Form-styling solution that is both accessible and portable
This is an example of what you can do by combining and tweaking type using css. I am not at this time going to be describing the code in much depth, but if you are interested in learning how I did it download my advanced css typography example page and look through the source code.
All 5 are CSS based and demonstrate various techniques and looks including typewriter, fancy headlines, handwriting.
The aim is to apply underlines to paragraph text that stretch the whole width of the column (without using justified text), regardless of the lengths of the paragraph text itself.
- Table headers are there but hidden using the aural text class discussed in a previous article. Sighted users have already received information on what the chart is about.
- A bar is created using an image which is stretched to the appropriate size.
- Bar widths are calculated relative to the largest value.
- Value cells have a repeated background image which shows the vertical lines.
- Browsing the chart without CSS or images will render an ordinary table.
- Value labels can be hidden by using the aural text class.
Here you use pre-made background images to shade in the appropriate data.
Use CSS to show nice looking bar graphs based on just div and span tags
Here you find two examples of styling lists into horizontal bar charts. Each definition list item is assigned a class that adjusts its width using percentage units.
Easy way to display a simple percentage graph using PHP to work out the percentages and do the maths and CSS to display the data on our page.
Data visualization is mostly achieved with flash applications or with help of some programming languages. Are those solutions the only way to present, let’s say simple data chart? How about giving it a try with nothing but good ol’ css?
This vertical bar graph is done completely using DHTML and CSS! Unlike an applet based solution, this loads fast and blends in with the rest of the page. You can even use a transparent background for it!
This is simple bar-graph that shows data by month.
This simple technique just adds bars to a list of items behind the text (check out the finished example for an idea of what we’re shooting for). It works for lists of any length. Longer lists benefit from being sorted by count since the relative values of the bars are easier to read when they are sequential. In this example, we’re going to display the count for each item in the list, but you can leave that out if the value is less important on its own and you’re just showing the relative values for comparison.
There are plenty of CSS bar graph interpretations, but none of them did stacked bar graphs. So I’ve done it here. Based off Alen Grakalic’s Pure CSS Data Chart.
Using CSS and PHP you can create attractive bar graphs (yes, even the stacked kind) that are always up to date.
This technique takes structured html, replace text with images and by using css sprites and absolute positioning it creates a simulation of a line graph.
This line graph is done completely using DHTML and CSS! Unlike an applet based solution, this loads fast and blends in with the rest of the page. You can even use a transparent background for it!
A scatter plot is a great way to graph two-dimensional data. Each data point is clickable in this solution.
This is a purely DHTML/ CSS based Pie Graph script. It loads fast and blends in with the rest of the page. You can even use a transparent background for it!
By default, an image element that is 500 pixels doesn’t exactly play nice with a container as large as 800 pixels or one as small as 100. What’s a designer to do?
A tutorial with various CSS examples for how to create a large background using either a single image or double images.
In fluid layouts, formatting text to adjust smoothly to window size is easy, but images are not as fluid-friendly. This quick tip shows how to switch between two image sizes based on the size of the browser, the DIV or whatever else you choose.
Want layouts that still work if a user increases their browser’s text size? Resize images in order to stay in proportion with the content.
Scroll the page to watch a battle between good and evil take shape. The effect requires two images: one transparent and one tiled gradient image. The gradient scrolls under the transparent PNG. Because it matches the colors in the PNG, each set of images disappears, depending on the part of the gradient they’re on top of.
This article summarizes three fast and easy CSS techniques for displaying only a portion of an image. All of the techniques need only a couple of lines of CSS. You are not literally cropping, which is why it’s called faux image cropping. These techniques can be helpful if you want to keep images to a certain size (for example, thumbnails in a news section). Being able to use CSS to control which portion of an image to display is great.
Visitors browsing at slow connections have to wait until large images load and they don’t have a clue something is missing — they see an empty block of space between two blocks of text. Image preloader will solve this issue.
Using this method you’ll get a clickable image when style sheets are active, and a standard button when style sheets are off.
A picture’s worth a thousand words, right? So spice up those plain old text links with Link
Shapes with Css, Rounded Corners and more
This example demonstrates the way that the CSS above sets the background images on either end of the box, while assigning a background color to shine through the transparent portions of the images.
Here are three techniques for incorporating data visualization into standards-based navigation patterns.
Put nine different techniques of image replacement to the test.
This collection of techniques to create boxes with rounded corners using CSS has become quite popular. The problem now is there are so many choices it’s hard to know which one to choose.
This tutorial teaches you how to control thumbnail sizes. Sometimes we don’t have enough space to fit large thumbnails, and yet we would rather avoid small indecipherable images. Using this trick, we can limit the default dimensions of thumbnails and show them at full size when the user mouses over them.
I bet a bunch of you don’t realize that we can create the illusion of shapes by using 100% CSS. By utilizing the border property in creative ways, we can make some really interesting polygons. In this week’s screencast, we’ll figure out a way to create speech-bubbles without resorting to background images.
Thechniques that help you create various types of Pullqoutes.
This solution relies on CSS Sprites and a few lines of jQuery, but it requires a bit of preparation before implementation. It is not recommended for large-scale projects; it is probably best for portfolio pieces.
How to produce a single, semantically logical ordered list that wraps into vertical columns.
How to Create a Block Hover Effect for a List of Links
The secret to creating printable pages is being able to identify and control the “content area(s)” of your website. Most websites are composed of a header, footer, sidebars/subnavigation, and one main content area. Control the content area and most of your work is done. The following are my tips to conquering the print media without changing the integrity of your website.
How to insert the value of an anchor’s href attribute, in-line, after the text, slightly smaller and flanked by parentheses for printing web pages
This document describes some of the issues concerning the use of CSS to reformat Web documents for printing
On this page I explain some of the new CSS declarations to be used with tables.
large collection of CSS Grid Systems, online generators and tutorial on how to use these in your design. Using a CSS Grid System is really worth considering if you’re planning to create a complex magazine web design. This article will give you the overview and tools you need to get started.
Why use a framework? Besides saving time, there are lots of reasons: standardizing the organizational structure of your sites, avoiding dumb little mistakes, and browser compatibility. Sounds pretty compelling, but there are certainly reasons not to use them as well. For example, a framework might be too much for the site you are designing and it’s basically just unnecessary bloat. Another common argument against frameworks is that CSS and XHTML go hand in hand, they need to be designed and constructed together, so using pre-written CSS just isn’t an option.
Grid 960 is a CSS Framework that enables developers to rapidly prototype designs. They are excellent tools for creating mock ups. Why? Because they do all the heavy lifting allowing you to get faster results.
WP_Query is a powerful tool to control what comes out of your loop. Today I’m going to teach you all how to use it to make a 3 columned newspaper theme that has all your main blog posts in the main column, and off to the side a set of posts with a certain category. We’ll be using the 960 CSS framework for the basic layout and reset of our theme, it will chop a lot of work off what’s needed!
This module describes integration of grid-based layout (similar to the grids traditionally used in books and newspapers) with CSS sizing and positioning.
A clean, simple a nice navigation menu, designed by Nick La.
MyCSSMenu provides the average webmaster with tools to create custom, cross browser compatible css menu. Our generator makes it easy to create custom web navigation: Horizontal, Vertical, Drop-down menu without having to know all the complicated HTML and CSS. If you are a more experienced web developer we provide the sources code for all our CSS menus so that you can download, tweak, and integrate as much as you want. Feel free to use our CSS menu generator an unlimited amount of times.
Generates both the CSS and the HTML code required to produce a text-based yet appealing set of navigation buttons. As text links are fast becoming preferred over images where search engine optimization is needed, a CSS menu can give the effectiveness of text links with a better look than standard text links. For an example of a CSS menu, look at our navigation on the left.
Candy Menu is a stylish CSS drop down menu that’s comes in six provocative colors to get you started.
What we want to do here, is instead of simply altering the state of the navigation item the user is currently rolling over, we want to alter the non navigation items as well. This will help focus the users attention on the item they have selected on, and create a new look and feel for the site overall. Want to see it in action? Look at my demo page before we start.
A tool to optimize and format your CSS. Note that your code should be well-formed. This isn’t a validator which points out errors in your CSS code.
This tool can really make your come more neat!
Use this utility to compress your CSS to increase loading speed and save on bandwidth as well. You can choose from three levels of compression, depending on how legible you want the compressed CSS to be versus degree of compression. The “Normal” mode should work well in most cases, creating a good balance between the two.
CSSTidy is an opensource CSS parser and optimiser. It is available as executeable file (available for Windows, Linux and OSX) which can be controlled per command line and as PHP script (both with almost the same functionality). In opposite to most other CSS parsers, no regular expressions are used and thus CSSTidy has full CSS2 support and a higher reliability.
Offers a variety of options, among them – Style Rule Settings, Style Property Settings, Alphabetizing Feature and De-Capitalization Feature.
“I absolutely hate having to switch all the ‘< ‘ and ‘>’ signs in my code to ‘<’ and ‘>,’ respectively. I also hate having to write “&” any time I want to include an ampersand. It makes including code snippets on my blog and whatnot extremely annoying, and today I finally got fed up.” This handy tool is a little app that will do all that for you. Created by Elliot Swan.
Creates a fluid or fixed width floated column layout, with up to 3 columns and with header and footer. Values can be specified in either pixels, ems or percentages.
Upload an image to generate a color palette based on the image’s primary colors. Useful for quickly grabbing a particular color within an image for inspiration.
This page contains a neutral colors chart and a general-purpose color chart. You can use the colors in the palettes with either HTML or CSS. Click on the color code to select it, then you can copy and paste it. Click on the Toggle button to convert from Hex to RGB and back. The charts are printed in tabular fashion so you can narrow your browser window with the palette and compare the colors to your design side-by-side.
CSSEdit is another fantastic web dev app, which takes Apple’s WebKit by the reigns to deliver a fantastic real-time visual CSS editing experience. But that’s just it! People only know it as a visual CSS editor, when it is actually much more! I use these 5 fantastic tips to keep my work flow fast and smooth.
List-o-matic lets you choose the content, layout and presentation of your list-based navigation menus. Just give it a go – it’s child’s play!
Markup Maker takes a simple list of page ids that you enter and converts it to a valid XHTML/HTML document (scaffolding, if you like). Now includes HTML5 support
CSS Mate is an online CSS editor.
A tool to generate HTML and CSS for rounded corner boxes.
A PHP/HTML/CSS template generator that creates a two column layout with both a header and a footer. This PHP / CSS Style Sheet template generator outputs full featured tableless code i.e. tables are NOT used for the template with the column layout. The resulting template is a combination of several files i.e. this is a true PHP, html, CSS template that makes it easy to control multiply pages at a web site.
An online tableless layout generator that allows you to create and customize layouts easily only by completing forms, making creating skins for your Firdamatic-based layout a breeze. This tool is available for free for personal/non-commercial use only .
Yields a three column layout without using any Tables. This HTML & CSS Style Sheet template generator outputs a full featured 3 column template. Resulting in an instant web page with a customized template that can be used to control the look of an entire site.
HTML/CSS form generator that creates a nice looking layout for forms. Add a ‘little color’ to the forms.
There’s a lot of cheat sheets available for CSS, html and any other web technology. I have picked a few that I believe stand out because they are able to assist you remembering important elements of key web technologies or because they are really well structured. Print out your favorite Cheat Sheet and put it on the wall just next to your monitor to get instant access to help and reference.
Good looking and well structured CSS overview
The CSS cheat sheet is a one-page reference sheet, listing all selectors (as of CSS 2.1) and properties. It includes a visual example of the box model, unit reference for CSS units and the various media types CSS makes allowance for.
All you need to know about CSS in 3 parts. These documents go through all important aspects of CSS on a minimum number of pages.
Get help with some of the CSS elements that are so easy to forget.
Good looking and well structured html overview
The information is pretty much just a copy of what is found in the WHATWG specs, just condensed and hopefully a bit easier to read. There are virtually no explanations, however, and no examples other than some graphics for compositing values and a few other things (the appearance of which is very much inspired by those found in Mozilla’s examples). So, it’s basically just a listing of the attributes and methods of the canvas element and the 2d drawing context.
The RGB Hex colour chart is a very large (183kB) PNG file, and is sized to fit on a standard A4 piece of paper. It shows the 216 so-called “web safe” or “non-dithering” colours (there are actually only 22 web safe colours, but those are revolting).