CSS, CSS3, Web, Web development

Learning CSS

CSS (Cascading style sheets) is nothing but like a helping hand to present your website in an organized and presentable way with various styling. The name itself dictates the objective of CSS. Yes, its generally used to put styles to your web pages, of your choice of course. In a bit deeper prospect, CSSs are kind of mandatory documents, if you are going for the development of a good looking website. Assuming, you are a newbie to CSS, let us start with how to put it in use when coding an HTML document. Well, there are a few ways to mix it with your HTML document.

  • Internal / Embedded styles
  • Inline styles
  • External styles

All of above ways are valid to define stylea for the elements coded in your HTML document, with certain pros and cons. Most favorable approach is the third one (External styles), where external documents are created with .css extension which are used to write all your style rules in there. Later on a CSS document is simply needs to be linked to your target HTML document for which you have written all the style rules. The linkage task is accomplished with a <link> tag on your HTML <head> section (Preferred position).

In a CSS document generally we code the style rules using with two prefixes

  • # (referred as id attribute of any tag in HTML code and should be applied once in an HTML document)
  • . (referred as class attribute of any tag in HTML code and can be applied n times at an HTML document)
  • Direct to any selector of the HTML document [i.e. *, body, div etc]

Here * refers to all the tags used in target HTML document.

The very basic and a standard structure of an HTML page is as follows

@charset "utf-8";
selector-name { property: value; }
# { property: value; }
. { property: value; }

As you can see above, CSS rules are just simple combinations of property name and corresponding value for the same. Here, property name can be color and value for that can be, say, red/#ff0000/rgb(255, 0, 0).

CSS has got a few upgrades (at this time CSS3) with a lot more attractive and useful capabilities. You got to know about all these with time. Learn step by step to get everything digested in a proper way.

An ample number of online resources are available around the web which are good enough to  start learning CSS in details. I’m going to refer the best ones for you.

Here sharing some useful resources links to get you started with CSS/CSS3:

Nevertheless, if you get any confusion while going through the tuts or get any question on mind, feel free to write to me. I’ll try my level best to reach you ASAP with assistive answer. Will go to next level soon!


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s