I’m creating a invoice and have option to print the invoice. While printing i use a stylesheet (using media=print) to block the display of elements which should not be printed…
But while printing it takes the full size of the window and uses that much paper..
I want to restrict the size of the printing area…. How can i do that?
Without seeing the CSS on the original page I can’t really be sure, but make sure you are using display:none rather than visibility:hidden to remove the areas you don’t want to print.
If you have any widths set on the body or containing elements you could try removing/reseting them.
Or maybe have a look at some CSS print frameworks such as hartija http://code.google.com/p/hartija/
Good luck,
Jedidiah
edit: Just read your comment to Steven Paligo. If the rows are in a table could you try setting a fixed or maximum height on the TR.