PDA

View Full Version : How 2 avoid printing a specific image ?



Yovav
Nov 8th, 2002, 10:15 PM
Hi all,

how can I exclude a specific image from being printed
(I know it;s something related to "@" CSS)

anyone knows the syntax ?

MCookie
Nov 9th, 2002, 08:15 AM
One way to do that is to use a second stylesheet. The second one will only be used when someone wants to print the page.

<link rel="stylesheet" media="all" href="style.css" type="text/css" />
<link rel="alternate stylesheet" media="print" href="print.css" type="text/css" />

Put your image in a div with an id and set it to not display in the print.css.


#noprint {
display:none;
}

<div id="noprint"><img src="" width="" height="" alt="" /></div>