Page 1 of 1

How to print a web page using php?

Posted: Fri Jan 02, 2009 1:08 pm
by shellom2005
hi ,how to print a web page using php.I'm new and i have very little php knowlege.please help!

Re: How to print a web page using php?

Posted: Fri Jan 02, 2009 1:11 pm
by omniuni
If I catch your question correctly, I don't think you even need PHP.

Code: Select all

<input class="NavButton" id="btnPrint" type="button" value="Print Me!" onclick="window.print();">
That triggers a print dialogue.

If you want, you can have PHP generate a new page, though, with more printer-friendly CSS, or simply write a CSS file that is specified for print media.