Search This Blog

Thursday, April 7, 2011

new learn ................................


Tag Selector

The tag selector applies to specific XHTML tags, as we saw in the previous examples. The selector consists simply of the tag name as it appears in the XHTML source, but without the angle brackets. The following example removes the underlining from all anchor elements and changes the base font-size of the text within the page to 20 points. The body tag is one of the top-level tags automatically created by Seaside enclosing the whole page.
a { text-decoration: none; }
body { font-size: 20pt; }

What is a CSS ID Selector?

A CSS id selector applies to the one element in the HTML document with the specified ID. But unlike classes, each ID must be unique on the page.
<p id="bordered">
Or
<div id="bordered">
The id selector is then defined with a hash- or pound-sign (#) before the id name. You can set a id:
#bordered {
border : 1px solid black ;
}
You can also set a id selector including the specific element that has that id. Do this by placing the type selector before the hash-sign in the id selector without any spaces:
div#bordered {
border : 2px solid red ;
}

1 comment:

  1. So the important thing now is to rewrite this information in your own words. That is the only way to really make it yours.

    We aren't studying XHTML, for example, but HTML 5. Most of the knowledge of one will transfer to the other with only a little adaptation, but the adaptation is important - it shows you really know what you are doing.

    ReplyDelete