|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Make Print Useless Using CSS
I'm trying to prevent users from printing my pages. I'm not looking for something too serious, just enough to deter the average user. Right now I have the following in my css file:
@media print { BODY { display:none; } This works pretty well and just gives a blank page if someone tries to print. However, this was tested on a mac using IE 5.1 and it didn't work. Is there a way to make this method work across platforms and with different browsers? Thanks in advance. John |
|
#2
|
||||
|
||||
|
It may be that MAC doesn't understand the @ in the stylesheet parameters. If you use <link> it should work, like so:
Code:
<link rel="stylesheet" type="text/css" href="default.css" title="default" media="screen" /> <link rel="stylesheet" type="text/css" href="print.css" title="default" media="print" /> Code:
BODY {
display:none;
}
__________________
Cheers, Jamie # skiFFie | Home of the 'accessibility module' for Drupal # Jamie Burns [me] Accessibility Module [drupal] # guidelines | search | wap resources | not getting help | fold to cure __________________ Let the might of your compassion arise to bring a quick end to the flowing stream of the blood and tears ..... Please hear my anguished words of truth. ![]() __________________ |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > Make Print Useless Using CSS |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|