[WEB4LIB] Re: Netscape 4.x and [media="all"]

mlsamuel mlsamuel at isl.state.id.us
Mon Jan 13 16:49:17 EST 2003


I ran into this NN 4.x media="all" problem when working on our library's
redesign.  The thing I wanted was for the stylesheet to apply to not
only the screen view, but also to prints.

The solution I hit upon was to declare the stylesheet twice, once for
the screen, once for prints.  NN 4.x has no problems with this.

Like so:
<link rel="stylesheet" href="stylesheet.css" type="text/css"
media="screen">
<link rel="stylesheet" href="stylesheet.css" type="text/css"
media="print">

Michael Samuelson
Web Design Specialist
Idaho State Library
mlsamuel at isl.state.id.us
(208) 334-2150 x 248


-----Original Message-----
From: Robert Sullivan [mailto:rsullivan at sals.edu] 
Sent: Monday, January 13, 2003 2:29 PM
To: Multiple recipients of list
Subject: [WEB4LIB] Re: Netscape 4.x and [media="all"]

> >Netscape Navigator 4.x incorrectly ignores any linked or embedded
style
> >sheets declared with MEDIA values other than screen....
>
> This is actually one of the tools you can use to make sure that NS4
doesn't
> see CSS properties that would confuse it.  A similar trick uses
@import.

As it happens, I wasn't trying to hide the sheet, I just thought there
might be some benefit in specifying that setting.  My style sheet is
pretty basic and Netscape 4.x handled it tolerably well until I added
that attribute.  I will just have to accept the default.

The error mentioned by Lisa Pons was from a Javascript counter; I'm
phasing those out because it's very difficult to get them to validate.
Thanks for the quick answers!

Bob Sullivan  <rsullivan at sals.edu>
Schenectady County Public Library (NY)  <http://www.scpl.org/>
Schenectady Digital History Archive
<http://www.schenectadyhistory.org/>






More information about the Web4lib mailing list