HTML and CSS Reference
In-Depth Information
Cascading Style Sheets
Cascading Style Sheets provides a style sheet language for HTML. The majority of present-
ational features that remained in HTML from the pre-CSS days have now been removed in
HTML5, and all presentation should now be performed entirely with CSS.
CSS provides a separation of concerns, and allows the styling of a page to change independ-
ently of its content, and vice versa. HTML is responsible for conveying the meaning of the
web page, while CSS conveys its presentation.
This also means that the same content can be repurposed for different devices (such as mo-
bile phones) by simply providing a new style sheet.
CSS provides a set of properties that describe how elements in the document should be
styled when then match certain rules, and how they should interact with one another. The
styles that can be applied to elements is mind-boggling, and has been significantly extended
in CSS3, which is a specification largely running in parallel with HTML5.
It is usually not important for a software engineer to have an intimate knowledge of all CSS
features, however it is important to understand the fundamentals, otherwise a huge amount
of frustration and agony can ensue. As with all the languages addressed in this topic, CSS is
not as simple as it may appear, and a strong grasp of its fundamentals is important for any-
one involved in the development of web applications.
We will largely ignore CSS during the development of the sample web application in this
topic. However Appendix A: Cascading Style Sheets provides an in-depth introduction to
CSS, and you can skip to that section any time you need.
Search WWH ::




Custom Search