...

View Full Version : Forced Landscape Printing



undyingfires
11-26-2002, 02:32 PM
I know that forcing a landscape or portrait printout from a webpage is probably not going to happen due to local settings...
However, here's the situation:

We have a map that stretches across two 8x11 regular sheets (portrait) and when we print it from our web page, of course you only get one half or if landscaped, more (no full) of the image.

Other then shrinking the image to fit portrait size (which would greatly ruin the quality of the image) is there any way - other then turning (rotating) the image on its side - to possibly force the visitor to print landscape?

The next best thing I can think of, is to simply suggest landscape printing...

Geze, I hope that wasn't too confusing. :o


thanks!

redhead
11-26-2002, 05:59 PM
try this...

http://www.codingforums.com/showthread.php?threadid=10073&highlight=print+landscape

MCookie
11-26-2002, 06:14 PM
The best thing I can think of is keeping two images on the server (one for viewing, one for printing), two images on your page (one for viewing, one for printing), and two stylesheets; again; one for viewing, one for printing.
When the page is viewed, the div with the rotated image is hidden (display:none;).
When a user wants to print it, the div with the portrait image is hidden and the rotated image visible. That's possible like this:

<link rel="stylesheet" type="text/css" media="screen" href="style.css">

contains:

#print {
display:none;
}



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

contains:

#view {
display:none;
}


<div id="view"><img src="" width="500" height="300"></div>
<div id="print"><img src="" width="300" height="500"></div>


But the browser always loads two stylesheets and both images.

undyingfires
11-26-2002, 06:51 PM
Wow great thanks.
I'm going to suggest this to the fella respon' for this and see what he thinks. :)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum