Today I received an E-Mail from a good friend who just inherited a website and wants to learn how to make it work.  His question was easy to answer but the implementation needed to be discussed. So today I wanted to review the different ways we can add style to a website.

Some of you may know the term  In-Line style.  If you don't then the basic idea is you can add the style setting to any HTML tag and put your markup in there.  This is great for small sites or sites that only need a few styles.  I've used this even when including a full style sheet for my web site. There are just times where you only need to make the change to one section of the site. I'll admit this is not the most efficient way of adding style to page.

The other way is to have add your markup inside the HTML document between the <style></style> tag.  This isn't a bad solution if your needing to just add a small amount of markup to your page.  Again when I've created websites this is something I'll use but very localized.

Now then the most prefered way and the one I use every day is inlcudeing a style sheet.  This has a lot of benifits for a web developer. One you can have a large site and be able to mark up your website once and every page in the site will follow your design.  When your asked to make a color change on a section of text you'll be able to say "No problem let me pull that up and make the change as requested." and your done.  I don't want to tell you the number of times my client has asked can you make that a different color.  In the old days it was a nightmare for that question because we didn't use CSS yet.

Another benefit is the browser will check the date on the CSS file and if it hasn't changed it will try and use a cached version. This will help speed up web reloads to your site and reduce the amount of traffic you website will generate.  May seemlike a small amount but in the long run everything helps.