CSS: the Basics

picture of keyboardCSS, or Cascading Style Sheets, formats and customizes HTML or other files in markup language. With CSS, coders can change the layout, font, colors, and other design elements of a webpage. Coders can ascribe attributes such as "class" or "id" in HTML in order to apply the markup to specific parts of the HTML document. CSS uses a combination of brackets like "{}" and semi-colons to create lists of attributes for style elements.

Common CSS Attributes

Getting Started

Like HTML, coders write CSS in a text editor such as Textwrangler for OSx. The HTML file must link to the appropriate CSS file, and the CSS file must be saved with ".css" as the file extension.