By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,689 Members | 1,106 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,689 IT Pros & Developers. It's quick & easy.

A different font-size on Print ?

P: n/a
Hi NG

I have a site where an invoice is shown on the screen in a IFrame.
I have this script on the site:
<script type="text/javascript">
function zPrint(oTgt)
{
oTgt.focus();
oTgt.print();
}
</script>

and this :

<iframe name="myFrame" id="myFrame" width="544" height="364"
src="InvoiceIframe.php?Invoice=<?echo $invoice;?>"></iframe>
<input type="button" value="Print Invoice" onclick="zPrint(myFrame);">

The site now has the invoice written in an iframe on the screen, but when I
click print, the printed invoice is very small.
It is written with css font-size: 9px and font-family: verdana which is
fine for the screen and matches the rest of the site.

But it is way to small when it is printed.
So is there anyway to write it with font-size: 9px on the screen but printed
with a larger font-size ?
Feb 7 '07 #1
Share this Question
Share on Google+
2 Replies

P: n/a
Yes, use an external CSS file for print.
Read more about it here:
http://alistapart.com/articles/goingtoprint/

Regards Jens Peter Karlsen. Microsoft MVP - Frontpage.

On Wed, 7 Feb 2007 13:03:03 +0100, "EnjoyNews" <mh********@mail.dk>
wrote:
>
So is there anyway to write it with font-size: 9px on the screen but printed
with a larger font-size ?
Feb 7 '07 #2

P: n/a
Thanks alot.
It works like a charm :o)
"Jens Peter Karlsen [FP-MVP]" <jp*******@mvps.orgskrev i en meddelelse
news:uf********************************@4ax.com...
Yes, use an external CSS file for print.
Read more about it here:
http://alistapart.com/articles/goingtoprint/

Regards Jens Peter Karlsen. Microsoft MVP - Frontpage.

On Wed, 7 Feb 2007 13:03:03 +0100, "EnjoyNews" <mh********@mail.dk>
wrote:
>>
So is there anyway to write it with font-size: 9px on the screen but
printed
with a larger font-size ?

Feb 8 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.