且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何加载 PEAR 包

更新时间:2023-02-21 22:50:43

大多数 PEAR 包必须通过通常的 include()require() 函数来包含.它们不是预编译的二进制文件,就像(比如说)MySQL 驱动程序 (mysql.so/mysql.dll) 一样.只要/usr/lib/php 在你的include_path 中,PHP 应该能够在你执行include('nameofpackage.php') 时自动加载包.

Most PEAR packages have to be included via the usual include() and require() functions. They're not precompiled binaries, like (say) the MySQL driver (mysql.so/mysql.dll) are. As long as /usr/lib/php is in your include_path, PHP should be able to load up the package automatically when you do include('nameofpackage.php').