doujiang9887 2013-01-02 20:07
浏览 98
已采纳

NetBeans Include Path未被完全搜索,无论是项目,全局还是PHP

I am having a great deal of trouble with NetBeans 7.2.1 using PHP and the Include Path. This may or may not be related to Netbeans PHP Include Path seems unused, either Project or Global where I state that NetBeans is not using its Project or Global Include Path. However, in this case, NetBeans is not searching the entire PHP Include_Path variable.

The PHP Include_Path is listed in the error messages. The file AutoloaderFactory.php is in D:\PHP\zf2-tutorial\vendor\zendframework\zendframework\library\Zend\Loader;

However, when I try to use NetBeans/Tools/Create PHPUnit Tests, I receive a series of warning and error messages saying that AutoloaderFactory.php is not found. These messages search only three of the provided libraries which do not include the library with the required class.

As a NetBeans noob, I am obviously not understanding something about it. But, I can't build my project because it won't find the required classes no matter what I do, including using Project, Globabl and PHP Include Paths. Can someone help me?

The error messages are included below. Thanks...RG

PHPUnit Skeleton Generator 1.2.0 by Sebastian Bergmann.

Warning: include(D:\Program Files (x86)\Zend\ZendServer\share\ZendFramework\library\Zend\Loader\AutoloaderFactory.php): failed to open stream: No such file or directory in D:\PHP\zf2-tutorial\init_autoloader.php on line 38

Call Stack:
    0.0007     321856   1. {main}() K:\phpunit-skelgen:0
    0.0062     472944   2. SebastianBergmann\PHPUnit\SkeletonGenerator\Command::main() K:\phpunit-skelgen:45
    0.0167     980480   3. ReflectionClass->newInstanceArgs() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0167     980936   4. SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator->__construct() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0178     987216   5. include_once('D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php') K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator.php:125
    0.0213     993680   6. require_once('D:\PHP\zf2-tutorial\init_autoloader.php') D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php:4


Warning: include(): Failed opening 'D:\Program Files (x86)\Zend\ZendServer\share\ZendFramework\library\Zend\Loader\AutoloaderFactory.php' for inclusion (include_path='D:\PHP\Includes;D:\PHP\zf2-tutorial;D:\PHP\ZendProjects\htdocs\Includes;D:\PHP\zf2-tutorial\vendor\zendframework\zendframework\library;D:\Program Files (x86)\Zend\ZendServer\share\ZendFramework\library;K:\pear') in D:\PHP\zf2-tutorial\init_autoloader.php on line 38

Call Stack:
    0.0007     321856   1. {main}() K:\phpunit-skelgen:0
    0.0062     472944   2. SebastianBergmann\PHPUnit\SkeletonGenerator\Command::main() K:\phpunit-skelgen:45
    0.0167     980480   3. ReflectionClass->newInstanceArgs() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0167     980936   4. SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator->__construct() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0178     987216   5. include_once('D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php') K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator.php:125
    0.0213     993680   6. require_once('D:\PHP\zf2-tutorial\init_autoloader.php') D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php:4


Fatal error: Class 'Zend\Loader\AutoloaderFactory' not found in D:\PHP\zf2-tutorial\init_autoloader.php on line 39

Call Stack:
    0.0007     321856   1. {main}() K:\phpunit-skelgen:0
    0.0062     472944   2. SebastianBergmann\PHPUnit\SkeletonGenerator\Command::main() K:\phpunit-skelgen:45
    0.0167     980480   3. ReflectionClass->newInstanceArgs() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0167     980936   4. SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator->__construct() K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\Command.php:171
    0.0178     987216   5. include_once('D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php') K:\pear\SebastianBergmann\PHPUnit\SkeletonGenerator\TestGenerator.php:125
    0.0213     993680   6. require_once('D:\PHP\zf2-tutorial\init_autoloader.php') D:\PHP\zf2-tutorial\module\Album\src\Album\Controller\AlbumController.php:4
  • 写回答

2条回答 默认 最新

  • duanche4578 2013-01-08 22:04
    关注

    I totally purged NetBeans and reinstalled it. That included doing a registry clean after uninstalling NetBeans. At this point, the PHP Include_Path is being searched. I do not know whether or not the NetBeans Include_Path is being searched but that is another problem and I am not even sure why I should care since that won't matter after implementation. I'd be glad to hear a better answer.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 如何用python向钉钉机器人发送可以放大的图片?
  • ¥15 vue3加ant-design-vue无法渲染出页面
  • ¥15 matlab(相关搜索:紧聚焦)
  • ¥15 基于51单片机的厨房煤气泄露检测报警系统设计
  • ¥15 路易威登官网 里边的参数逆向
  • ¥15 Arduino无法同时连接多个hx711模块,如何解决?
  • ¥50 需求一个up主付费课程
  • ¥20 模型在y分布之外的数据上预测能力不好如何解决
  • ¥15 processing提取音乐节奏
  • ¥15 gg加速器加速游戏时,提示不是x86架构