|
Cascading Stylesheets: 5 Reasons To Use CSS
|
By Hilco van der Meer
[Hits: 23769]
|
|
Cascading Stylesheets become more and more important in today'swebdesign.
But before you decide to get started using CSS you should knowwhy CSS is so important and what its advantages are.
1. The content is separated from the design
Because you are able to create a separate Stylesheet and link itto all your webdocuments, you have great control over how yourwebsite looks. So if you want to change a certain aspect of yourpage, you only need to alter one file: your Stylesheet!
This Of course, generates some great flexibility. Thisflexibility is not available when your website is using tablesfor layout, inline font tags or inline defined colors.
A single CSS file can contain positioning, layout, font, colorsand style information for an entire web site.
2. You site uses less bandwidth and loads faster
Because stylesheets are so lightweight, your website will loadmuch faster. The main reason is because you do not need tablelayouts anymore for the positioning of elements. Since textloads really really fast your website will be visible in aflash.
This means that visitors will be happier when surfing yourwebsite. They only have to download the Stylesheet once, andit's automatically reused for every page. So the only thing thatneeds to be loaded is the actual content.
On average a website will load five to ten times faster if itmakes use of cascading style sheets.
3. Your website will automatically gain better search engineresults
With CSS, you can position any element, anywhere you want. So ifyour menu is at the bottom of your HTML document, you can bringit up using absolute positioning. The reason this is useful isto make sure the search engine spiders pick up the main contentfirst.
Another advantage you automatically gain is that your HTML codeis much cleaner. So the search engine spider will not have toseparate the junk code from the real content.
So make sure you put your logo text and your menu at the bottomof your HTML document at put it at the top using CSS!
4. CSS is compatible with newer browsers
Because more and more browsers are used other than InternetExplorer on a Windows machine, you need to be sure that yourwebsite is accessible by all major and newer browsers.
By using webstandards, defined by the w3c, you are making sureyour content is viewable in the future.
Because there are so many browsers these days, it is impossibleto test your website in all these browsers on differentconfigurations. Coding to standards is then the only practicalsolution.
5. CSS can be used to display the same content on differentmedia.
Because you are able to define different stylesheets fordifferent media you have great flexibility in presenting yourcontent.
The printer for example, is a medium on itself. If someoneprints out your website, you will be able to modify the look ofit. Add an extra black and white logo, remove the advertisementsand change the colors to black and white values. It's all doneeasily by using cascading stylesheets. And the best thing is,visitors do not even have to know you created a new Stylesheetespecially for the printer.
Stylesheets can also be created specifically for PDA's and such.As you will understand, this adds some great flexibility to thepresentation of your web document.
Conclusion
Cascading Style Sheets are created to make things easier. Itgives you great control of your website and makes your visitorshappy when they are surfing your website.
You are prepared for the future and will gain better searchengine results automatically. Start using CSS to its fullpotential today! It will suit you well.
|
|
|
|
|
|