RE: Printing in windows
| From: | Nold, Mark | Date: | Thu, 21 Dec 2000 08:23:27 +0000 |
| Subject: | RE: Printing in windows | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-4573@lists.php.net to get a copy of this message | ||
----------------------------------------------------------------------------
-----------------
Disclaimer: The information contained in this email is intended only for the
use of the person(s) to whom it is addressed and may be confidential or
contain legally privileged information. If you are not the intended
recipient you are hereby notified that any perusal, use, distribution,
copying or disclosure is strictly prohibited. If you have received this
email in error please immediately advise us by return email at
postmaster@normandy.com.au and delete the email document without making a
copy.
----------------------------------------------------------------------------
-----------------
PDF is really the only option for crossplatform nicely formatted output.
Excel is also a possibilty (but of course Windows only).
<blatent plug>
Have a look at http://www.enspace.com/erpnet/demo/
It's a demo of PDF +
Excel via the web (the demo is in Flash).
</blatent plug>
The two options for PDF is PDFlib and htmldoc.
Since (i assume) you are a commercial org PDFlib will cost you $ in the
order of 1000's. BUT it is very worthwhile.
HTMLDoc on the other hand is simpler, slower and free.
I'd recomend you start with htmldoc (www.easysw.com/htmldoc) then move to
PDFlib when you have time.
Basically htmldoc allows you to write a html file and convert it to PDF via
a command line executable, since you probably want to write lots of tables
it works well... though you wouldn't have the complete control you would
have with PDFlib.
HTMLdoc will be slower (i think) since it would be an external program...
but... since you are retrieving and parsing 30 pages of info it wont be your
bottleneck. (BTW: Both PDFlib and HTMLDoc work in Windows and un*x)
PDFlib is quite fantastic. Whatever you wish to do you can do. But it takes
some thinking about and is very similiar to creating documents in Postscript
(which is not fun)
HTMLdoc is the quickest way to start doing what you want. What i would
recommend though is try to abstract the whole process via class's (or
functions) so that you can drop in PDFLib support easyly at a later date.
You should end up with something like;
$report->query("SELECT * FROM mytable WHERE myfield = '$variable'");
$report->type = "PDF";
$report->heading = "My Fancy Report";
$report->deliver();
By doing something like this you can easily rip out the code that uses
HTMLdoc and replace it with PDFlib or whatever strikes you fancy.
Mark Nold
-----Original Message-----
From: Ryan Conover [mailto:Rconover@americanbridge.net]
Sent: Thursday, December 21, 2000 2:42 AM
To: php-windows@lists.php.net
Subject: Printing in windows
I am working on an intranet within a company using php. The intranet will be
viewed through IE. On the intranet we have a bunch of apps that display
reports of information(could be 30 pages plus). We like to have a more
printable format, because regular printing in IE will just cut it off and
tack it on to the next page. Is their anyway to format this. So it will not
do it.
Ryan