CSS by keralaguest

VIEWS: 25 PAGES: 3

									Amanda Hauth

         According to the article, “Introduction to CSS” by Sam Hickson, “A Cascading
Style Sheet is a set of rules that specify how a HTML document should be presented”
(Hickson). Cascading Style Sheets have produced a way of creating a structure and layout
for websites without needing to add design elements to every html tag. With CSS,
designers can control fonts, colors, positions and all the other aspects of design on a
website. These specific formats can then be carried throughout the website’s other pages
by being linked to the .css document (external style sheet). Other ways that cascading
style sheets work will be discussed later in the paper.

        According to the first author, Sam Hickson, listed above, there are three types of
style sheets. These sheets are external, internal, and inline. First, the inline style sheet has
“the highest priority when formatting HTML, followed by the internal style sheet, and
finally the external style sheet” (Hickson). With this being said, Hickson then goes on to
explain that if one style sheet then conflicts with another in value, then the style sheet
with the higher priority will then be used. Inline style sheets “are contained within the
specific element’s tags, and will only be applied to that element”(Hickson). An inline
style sheet for example can be put in the <p> paragraph tag. This will just change the text
between these tags and not all the text in the document. Internal style sheets are between
the head tags and will only apply to elements in that one document. And finally, external
style sheets are “separate .css documents that are applied to elements in pages that they
are linked to”(Hickson). With this being said, external style sheets are included in the
head tags and allow a designer to apply the styles to other documents.

        To show the difference in style sheets, Taylor Anderson’s article "Cascading
Style Sheets Made Easy", states that “the best way is generally to use external CSS
files..."(Anderson). This allows the designer to control all the elements throughout the
entire site. This saves the designer time, instead of defining the same styles that you want
repetitively in each individual HTML file. However, the second way is to use style
sheets is by inserting style tags in between the head tags and using internal style sheets.
According to Anderson, “this is a good way to define styles you only use on one page;
otherwise you will want to use an external file sheet for two big reasons: Visitors only
have to load the sheet once, and you can control the styles for the entire site by editing on
page”(Anderson).

       In conclusion, in the article” What is CSS and why should I use it?”, for those
who web design frequently, there are three important reasons that CSS is very beneficial
to web design. These are flexibility, reducing the amount of code, and accessibility.
Flexibility, allows the designers to make formatting edits just in one document. For
example, when using an external style sheet on several pages and then deciding to change
the size of each page's title. A designer then does not need to go to each individual page,
but instead can go to the .css document and change it there. Also, according to this
article, when editing a table for example and using html tags, you must go to every
individual tag and change it to your desired size. However, with CSS, all you have to do
is change this within your external CSS file. Secondly, reducing the amount of code
refers to “streamlining” (What is CSS...) the file size of their documents. By doing this
the amount of extraneous code will be eliminated and your overall code can look cleaner.
Finally, accessibility refers to a webpage that can be used by those with disabilities. In
the article, the author talks about CSS and how it is more accessible to those who are
visually impaired.
                                     Works Cited



Anderson, Taylor. "CSS: Cascading Style Sheets Made Easy - WebReference.com-."
Web Development and Design Tutorials, Tips and Reviews - WebReference.com. 20
Oct. 2009 <http://www.webreference.com/programming/easy_css/index.html>.

Hickson, Sam. "Design with CSS - PSD to HTML or XHTML using W3C Standards
compliancy & Nice Clean Code." PSD to HTML/XHTML, CSS, W3C Standards
compliancy, Browser Compatibility, Hand-coded Markup, designwithcss.com. 20 Oct.
2009 <http://www.designwithcss.com/introduction_css.html>.

"The Cafes » Why CSS." The Cafes . 20 Oct. 2009
<http://cafe.elharo.com/web/refactoring-html/why-css/>.

"What is CSS (style sheets) and why should you use it?." web design, web development,
information technology, technical communication made simple. 20 Oct. 2009
<http://www.christopherjason.com/articles/what-is-css/>.

								
To top