HTML and CSS Reference
ers), aural (audio; speech synthesis, for instance), and all (many dif-
ferent types of media).
If you want to explicitly list several types of media, instead of specifying
all , use a quote-enclosed, comma-separated list of media types as the
value of the media attribute. For example:
<style type="text/css" media="screen,print">
tells the browser that your document contains CSS both for printing and
for computer displays.
Be careful specifying media, because the browser cannot apply the
styles you define unless the document is being rendered on one of your
specified media. Thus, the browser would not apply our example set of
styles designed for media="screen,print" if the user is, for instance, con-
nected to the Web with a handheld computer.
How do you create different style definitions for different media without
creating multiple copies of your document? The CSS2 standard lets you
define media-specific stylesheets through its extension to the @import
at-rule and through the @media at-rule, which we describe in section
8.1.5 later in this chapter.
22.214.171.124. The dir, lang, and title attributes
As with any HTML/XHTML element, you can associate a descriptive title
with the <!-- <DEFANGED_STYLE> tag and specify the language and text-
rendering direction with the title, lang , and dir attributes. [ The dir at-
8.1.3. Style-Free Browsers
Certainly you noticed that, in the preceding document-level stylesheet
example, we enclosed the contents of the <style> tag inside an HTML