CSS - Cascading Style Sheets

CSS – An Introduction

CSS stands for Cascading Style Sheets.

CSS is all about styling your website and making them look great.

HTML is used to structure content. CSS is used for formatting structured content. In the earlier days of WWW (World Wide Web), An author could mark his text by stating “this is a headline” or “this is a paragraph” using HTML tags such as <h1> and <p>.

HTML can be misused to add layout (like the earlier use of <table>) to websites. But CSS offers more options and is more accurate and sophisticated. It is supported by all browsers today.

Here is an example of HTML without CSS:

HTML page without CSS
HTML page without CSS

Same HTML with CSS:

HTML page with CSS
HTML page with CSS

As the Web gained popularity, Hakon Wium Lie gave the concept of CSS to provide web designers with sophisticated layout opportunities supported by all browsers. At the same time, the separation of the presentation style of documents from the content of documents makes site maintenance a lot easier.

CSS describes how HTML elements are to be displayed on the screen, paper, or in other media. It can save a lot of work. It can control the layout of multiple web pages all at once.

CSS lets you style the color, padding, size, position, and much more of a website so that it can look its best.

There a huge number of ways we can style our pages using Cascading Style Sheets.

One big advantage of using CSS is that it is completely separate from HTML. It does a handy job of keeping style and content separate. This generally makes your code more readable, easier to update and maintain. It has a very useful feature that you can completely restyle your website without actually changing the HTML of the content at all. So it lets you style the layout of your website, without changing its content.

Which benefits will CSS give me?

  • The control layout of many documents from one single style sheet;
  • more precise control of layout;
  • Apply different layout to different media-types (screen, print, etc.);
  • Numerous advanced and sophisticated techniques.

For more information about the types of CSS, Click here.

References:

http://html.net/tutorials/css/lesson1.php

http://www.w3schools.com/css/css_intro.asp

To read more of our blogs please visit the Fitness, Stories, and Tips for Work section.

Leave a Reply

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