Week 3 Exercise

1. What is the current status of CSS?
 
CSS is the language for describing the presentation of Web pages, including colors, layout, and fonts. It allows to adapt the presentation to different types of devices, such as large screens, small screens, or printers. CSS is independent of HTML and can be used with any XML-based markup language. The separation of HTML from CSS makes it easier to maintain sites, share style sheets across pages, and tailor pages to different environments. The current status of CSS is at level 3.0, also known as CSS3, and there has been 4.0 releases proceeding to this version which are the version 1.0, version 2.0, and version 2.1. below are the CSS work current and upcoming specification.

• Ruby – CR  • Media Queries - CR• Color – CR • User Interface – CR • TV Profile – CR • Selectors – LC • Fonts – LC • Pages Media – LC • Print Profile – LC • Web Fonts - LC

  2. What is the current status of XSL?

XSL allows the author to apply formatting operations to XML elements. XSL is a language in which the author can indicate that the 'footer' element should be displayed as a paragraph, in blue and in italic using Arial. XSL is not the only way to display XML data. However, it provides you with a simple declarative solution. Also, because XSL syntax is XML itself, you don't have to learn a whole new syntax to begin writing XSL stylesheets.The current state release of XSL was the version 2.0, whereas X- Query version is 1.0 and X- Path version is also 2.0. 


3. What are the relative merits of CSS and XSL?

The uses of style sheet languages have opened new possibilities and opportunities for web designers in terms of freedom in designing and maintainability of web sites. Currently, there are two kinds of style sheet languages used by many web designers today. These are cascading style sheet CSS and extensible style sheet language (XSL). While they are both called style sheet languages, they have very different purposes and ways of going about their tasks.

4. What are the implications of the concept of the document tree ?

The document tree – it’s a family thing

All HTML documents are trees. Each level of the tree is described in the same manner as a human family tree, with ancestors, descendants, parents, children and siblings. CSS rules are based on the document tree. If you understand the document tree concept, then CSS selectors will be easy to understand and apply.

Let’s start with a sample of HTML. This sample doesn’t include the head or title, as we are focussing on what is inside the body:

<body>
      <div id="content">
            <h1>Heading here</h1>
            <p>Lorem ipsum dolor sit amet.</p>
            <p>Lorem ipsum dolor <em>sit</em> amet.</p>
            <hr>
      </div>
      <div id="nav">
            <ul>
                  <li>item 1</li>
                  <li>item 2</li>
                  <li>item 3</li>
            </ul>
      </div>
</body>





The document tree diagram for the sample above would be:

Ancestor

An ancestor refers to any element that is connected but further up the document tree – no matter how many levels higher. In the diagram below, the <body> element is the ancestor of all other elements on the page.


Descendant

A descendant refers to any element that is connected but lower down the document tree – no matter how many levels lower. In the diagram below, all elements that are connected below the <div> element are descendants of that <div>.

Parent

A parent is an element that is directly above and connected to an element in the document tree. In the diagram below, the <div> is a parent to the <ul>.


Child

A child is an element that is directly below and connected to an element in the document tree. In the diagram above, the <ul> is a child to the <div>.

Sibling

A sibling is an element that shares the same parent with another element. In the diagram below, the <li>’s are siblings as they all share the same parent – the <ul>.

Links for more detailed information can be found on this website http://www.maxdesign.com.au/articles/workshop/