Creating a printable version of a page

It doesn't matter if you do all the error checking in the world, or if you have the most beautiful graphics, if your site or application design isn't usable, it's not going to do well. Get input and advice on usability and user interface issues here.

Moderator: General Moderators

Post Reply
User avatar
greyhoundcode
Forum Regular
Posts: 613
Joined: Mon Feb 11, 2008 4:22 am

Creating a printable version of a page

Post by greyhoundcode »

It isn't uncommon to see a printer icon with some title text along the lines of, "Click here to see a printable version."

What is the most common way of doing this? Would one normally use JQuery or equiv to change the stylesheet for example?
jmut
Forum Regular
Posts: 945
Joined: Tue Jul 05, 2005 3:54 am
Location: Sofia, Bulgaria
Contact:

Re: Creating a printable version of a page

Post by jmut »

Personal preference really. What would you as a user prefer? Not discussing the non-js enabled users here guess you got it thought of.
User avatar
greyhoundcode
Forum Regular
Posts: 613
Joined: Mon Feb 11, 2008 4:22 am

Re: Creating a printable version of a page

Post by greyhoundcode »

Can't say I'm particularly worried about non-JS users, my concern is to make this adaptation is quickly and painlessly as possible. What other methods might you suggest, if I wasn't to use JS for instance?
jmut
Forum Regular
Posts: 945
Joined: Tue Jul 05, 2005 3:54 am
Location: Sofia, Bulgaria
Contact:

Re: Creating a printable version of a page

Post by jmut »

Well simple link to another page that has additinal ?print or /print to distinguish. User wouldn't really care as long as it is printable.
I wouldn't recommend any popups etc etc. Clean page with the appropriate styling of course. People can easily say file -> print or file -> save as
User avatar
kaszu
Forum Regular
Posts: 749
Joined: Wed Jul 19, 2006 7:29 am

Re: Creating a printable version of a page

Post by kaszu »

I prefer using CSS with media print, that eliminates need for javascript :)
Hexi
Forum Newbie
Posts: 1
Joined: Mon Jun 22, 2009 4:18 am

Re: Creating a printable version of a page

Post by Hexi »

Thanks for taking the time to help, I really apprciate it.
infiniteacuity
Forum Newbie
Posts: 12
Joined: Tue Jun 16, 2009 2:48 pm
Location: Ft. Lauderdale

Re: Creating a printable version of a page

Post by infiniteacuity »

kaszu wrote:I prefer using CSS with media print, that eliminates need for javascript :)
I agree with this as it also contains it to 1 area for easy editing.
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Re: Creating a printable version of a page

Post by pickle »

kaszu wrote:I prefer using CSS with media print, that eliminates need for javascript :)
Not necessarily. He wants to have a webpage show the printable version, not just separate styling for printout.

While I would include the <link rel = "stylesheet" type = "text/css" href = "print.css" media="print" /> on every page, I think the best approach for making a "See what this page will look like in a printout" page would be to have the print icon point to a ?print page, like ~jmut suggested. On that page, do some PHP figuring to only include the print stylesheet if $_GET['print'] is present.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Post Reply