Gossamer Forum
Home : General : Internet Technologies :

PEAR and PHP?

Quote Reply
PEAR and PHP?
I'm totally confused as to what 'PEAR' is. I'm using this PDF generation module from;

http://www.rustyparts.com/pdf.php

When running the example2.php script, I get the following error;

Quote:
Creating the PDF...

Fatal error: Failed opening required 'PEAR.php' (include_path='/home/awnt/php:/home/awnt/htdocs/tools/phpMyAdmin') in /home/facer-ins/htdocs/pdf/HTML_ToPDF.php on line 16

...which, sure enough on line 16, has the following line;

Code:
require_once 'PEAR.php';

Does anyone know what PEAR is? Its not included in the script's distribution file, so I'm stumped Unimpressed

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] PEAR and PHP? In reply to
PEAR is the Perl equivalent of CPAN.

- wil
Quote Reply
Re: [Andy] PEAR and PHP? In reply to
http://pear.php.net/

- wil
Quote Reply
Re: [Andy] PEAR and PHP? In reply to
If you're looking for an alternative free pdf generation class that requires neither PEAR nor PDFLib, you might look at http://www.fpdf.org/. Quick and easy to use and very flexible, in my experience.

Fractured Atlas :: Liberate the Artist
Services: Healthcare, Fiscal Sponsorship, Marketing, Education, The Emerging Artists Fund
Quote Reply
Re: [hennagaijin] PEAR and PHP? In reply to
Thanks for the link, it looks pretty cool :) I don't see a 'save' function thought. There is a 'write' one, but that doesn't do what you would would think Unsure Do you know if there is a feature (and if so, what?).

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] PEAR and PHP? In reply to
By 'save' do you mean a function that creates the actual pdf file? If so, then you're looking for Output().

Fractured Atlas :: Liberate the Artist
Services: Healthcare, Fiscal Sponsorship, Marketing, Education, The Emerging Artists Fund
Quote Reply
Re: [hennagaijin] PEAR and PHP? In reply to
Aaah..I see. Using just Output() prints it to the browsers output, but if you define a value like Output("/path/to/file.pdf"), it writes it Smile I think I'll have a play with it now :p

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] PEAR and PHP? In reply to
You can also use:

Output('/path/to/file.pdf', true)

which generates a "Save As" alert window instead of displaying the file in the browser.

Fractured Atlas :: Liberate the Artist
Services: Healthcare, Fiscal Sponsorship, Marketing, Education, The Emerging Artists Fund
Quote Reply
Re: [hennagaijin] PEAR and PHP? In reply to
Wow...sweet Cool

The only thing I don't like, is that you have to manually create every table with the built in modules. PDFLib and htmldoc allows you to define a HTML page, and it will turn that into a PDF file. The PDF I am trying to generate is pretty large, and it will probably take a good few hours to even get the basic PDF done Frown

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates