Using PEAR for Applications

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
MKayHavoc
Forum Newbie
Posts: 9
Joined: Tue Feb 12, 2008 3:35 am

Using PEAR for Applications

Post by MKayHavoc »

I'm new to OOP and PEAR so just looking for some clarification.

If I build an app using PEAR and i use a package that isn't installed on a clients server and I don't have access to install the package, can the package be stored locally within the app?
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: Using PEAR for Applications

Post by Christopher »

Yes, you can include PHP files from anywhere you have access to. If you prefer you own local copy that is fine.
(#10850)
smudgeit
Forum Newbie
Posts: 2
Joined: Sat Oct 13, 2007 5:45 pm

Re: Using PEAR for Applications

Post by smudgeit »

Or if you want any script to be able to automatically include the files.

Try looking into setting the include_path

Code: Select all

ini_set("include_path", ".:../:./include:../include");
MKayHavoc
Forum Newbie
Posts: 9
Joined: Tue Feb 12, 2008 3:35 am

Re: Using PEAR for Applications

Post by MKayHavoc »

OK, that's great. Is there any guide or tutorial for doing this that you guys know of?
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: Using PEAR for Applications

Post by Christopher »

Other than the PHP manual, no. But it is very easy to just experiment a little with different paths to see how it works.
(#10850)
MKayHavoc
Forum Newbie
Posts: 9
Joined: Tue Feb 12, 2008 3:35 am

Re: Using PEAR for Applications

Post by MKayHavoc »

Ahhh.... go-pear, ingenious!
Post Reply