This example demonstrates most of the Feature Set #1 printing capabilities provided by MeadCo's MaxiPT print template. These are significantly more rich and customizable than those provided with Internet Explorer 5.5+ and are in fact much closer to Office.
Invoke Print Preview here or from IE's native controls to see it in action. You can view the source of this example here.
This note itself is hidden from previewing or printing by means of media="print" CSS.
When you're in Print Preview, please select the Extra... toolbar button. MaxiPT's Feature Set #1 incorporates the following properties:
To switch this functionality on, check the Activate
checkbox on the Extra... dialog in the top right corner of the Header and Footer group.
You can edit the HTML text for the header and footer directly using the input boxes
on this group. For example, an example set thus for the header:
"<div style="border: thin inset threedface; font: 15pt Comic Sans MS; background: lightskyblue; color: darkblue"> <center><i>--- Header for page <b> &p </b> ---</i></center></div>"will appear like this:
--- Header for page 3 ---
Shorthand | Meaning |
&w | Window title |
&u | Page address (URL) |
&d | Date in short format (as specified by Regional Settings in Control Panel) |
&D | Date in long format (as specified by Regional Settings in Control Panel) |
&t | Time in the format specified by Regional Settings in Control Panel |
&T | Time in 24-hour format |
&p | Current page number |
&P | Total number of pages |
"&w&bPage &p of &P"
To switch this functionality on, check the Activate checkbox
in the top right corner of the Header and Footer for The First Page
group. You can edit the HTML text for the header and footer directly using the input boxes
on this group.
If you switch it off, Header and Footer for The First Page will be set
to match the default Header and Footer.
This functionality can be set directly from script. So this:
document.printingRules.extraFirstPageFooter = "<div style="border: thin inset threedface; font: 15pt Comic Sans MS; background: lavender; color: orchid"> <center><b>Extra Footer</b>for the First Page;</center></div>"will appear like this:
Extra Footerfor the First Page
This functionality can be set directly from script:
document.printingRules.firstHeaderHeight = 180; document.printingRules.firstFooterHeight = 180; document.printingRules.extraFirstFooterHeight = 60; document.printingRules.allHeaderHeight = 120; document.printingRules.allFooterHeight = 120;All of these values will be calculated automatically if you don't set their properties.
This functionality allows you select the page range to print. It can be set from script:
document.printingRules.pageRange = "1,3-5,7,9-11";pageRange can also be set to "all" or "default".
This functionality allows you to specify how to print selected pages. It can be set from script:
document.printingRules.printingPass = "odd&even";printingPass can be set to "odd", "even" or "all" (same as "odd & even").
To switch this functionality on, check the Mirror Margins checkbox in the top left corner of the Printing Range group. It allows you to switch left and right margins as inner and outer margins for double-side printing. It can be set from script:
document.printingRules.mirrorMargins = true;Note: you can switch mirrorMargins on only for double-side printing, when Printing Range is set to "odd & even".