开发者

What's an appropriate include_path PHP/PEAR setting for Macports?

I'm using Macports for my PHP development. I thought that everything associated with Macports should be located under/opt/local, but I can't load the PEAR::Mail_Mime package I just installed through PEAR. I did confirm that the path to pear is /opt/local/bin/pear, but I have no idea where it dumped the package files, so I don't 开发者_如何学编程know how to include them in my path. Any pointers?


If you used the pear command to install the package, you could also do

$ pear list mail_mime

to get a listing of all files from that package and where they were installed to. It's a handy way of looking for example files, especially when used with grep ;-)


Pear files are typically installed in a share/php directory although I'm not on my mac right now so I can't check exactly where that might be. You can find that directory using locate though. From your terminal type:

$ locate PEAR.php

It should return something like /usr/share/php/PEAR.php - In this example /usr/share/php should be in my include path. Mail.php and Mail/mime.php should also be in this directory.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜