473,385 Members | 1,402 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

A different font-size on Print ?

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
2 7492
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
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 thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: John | last post by:
Now and again I like to start a sentence with a large capital, maybe in a different font. This upsets the line spacing and I've failed to find any css that will effectively crop the capital letter...
13
by: Tim Johnson | last post by:
Hello all: I have a page with two frames named "menu" and "display". An event handler in "menu" changes the src attribute for "display", resulting in a different page being loaded for each...
4
by: Glen K | last post by:
The following works in Firefox buy not in Internet Explorer: <select> <option> option1 </option> <option style="font-style: bold"> option2 </option> </select> Are there any workarounds to...
3
by: Robert Misiak | last post by:
Is it possible to have a different font in individual listView columns? When I do something like: ListViewItem lsi; .... lsi.SubItems.Font = new Font (lsi.SubItems.Font,...
4
by: Martha | last post by:
I have one tab control with 5 tab pages. I want to color each tab page a different color. Does anyone know how to color the entire tab page a unique color? (that includes the tab part of the tab...
2
by: ad | last post by:
I use a dataGrid to list the scores of students. If the score is less than 60, I want the score display with font of red. The other will display with blue font. How can I do that?
70
by: axlq | last post by:
I'm trying to design my style sheets such that my pages have similar-looking fonts different platforms (Linux, Mac, Adobe, X-Windows, MS Windows, etc). The problem is, a font on one platform...
1
by: bb nicole | last post by:
Below is my interface for resume which need to post into database... I have did it all in one page and it already can send into database which the table name resume... But my letturer now want me...
0
by: Hetal | last post by:
Hi, I have been working on creating a dynamic table with controls on a ASP.NET webpage and i have been using literal controls to do that. The issue that i am facing is, when i have the Start and...
1
by: Hetal | last post by:
Hi, I have been working on creating a dynamic table with controls on a ASP.NET webpage and i have been using literal controls to do that. The issue that i am facing is, when i have the Start and...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.