Selectors in DHTML
Three types of Selectors
- HTML selectors - the text portion of an HTML tag
- Class selectors - allows setting up of a class which can be applied to multiple HTML tags
- ID selectors - like class selectors but usually applied only once on a page to a particular HTML tag
In the example below IMG is the selector and SRC is an attribute of that IMG selector.
IMG SRC="picture.gif"
Note that the BR, FRAMESET and FRAME tags cannot be used as selectors.
Three types of HTML tags
- Block level tags have line breaks before and after
- Inline tags have no associated line breaks
- Replaced tags have set or calculated dimensions (width and height)