PHPExcel Class 'PHPExcel_Worksheet' not fo

2019-08-11 10:20发布

问题:

I got the following error when importing PHPExcel into my framework:

Fatal error: Class 'PHPExcel_Worksheet' not found in /var/www/library/phpexcel.class.php on line 109

I am autoloading my classes including PHPExcel but it looks like PHPExcel uses spl_autoload_register to register any existing autoloader functions with SPL. I also tried echoing the files as they were being loaded and got

/var/www/library/PHPExcel/Shared/ZipStreamWrapper.php
/var/www/library/PHPExcel/Shared/String.php
Fatal error: Class 'PHPExcel_Worksheet' not found in /var/www/library/phpexcel.class.php on line 109

So it seems Autoloader.php isn't the issue since ZipStreamWrapper.php and String.php are being loaded. Any suggestions at all would be appreciated, thanks!