Topics: Developer Forum, User Forum
Apr 21, 2009 at 12:04 PM
Edited Apr 21, 2009 at 12:07 PM
maybe someone can help: after browsing through the forum and searching goole for some hours I'm close to give up :-(. When trying to run /Tests/01simple.php (or any other script within that folder) I get the following error:

12:53:38 Create new PHPExcel object 12:53:38 Set properties 12:53:38 Add some data 12:53:38 Rename sheet 12:53:38 Write to Excel2007 format
Warning: file_exists() [function.file-exists.html]: open_basedir restriction in effect. File(/PHPExcel/Writer/Excel2007.php) is not within the allowed path(s): (/var/www/vhosts/ in /var/www/vhosts/ on line 201

Fatal error: Class 'ZipArchive' not found in /var/www/vhosts/ on line 285

Does anyone know how to get the script working on a "shared host server configuration"? Please help!

Thank you very much..
Apr 21, 2009 at 2:37 PM
Can you take a look at this thread and see if you have a similar weird include path?

Apr 21, 2009 at 3:07 PM
Hi koyama,

thanks for your quick reply! 

The path is  " .::../Classes/".

Greetings Trainer
Apr 21, 2009 at 3:42 PM
This is what I expected. Two adjacent semicolons in the include_path causing IOFactory trying to load files from root.

Work item created:

@trainer_p: You can help us solving this issue by trying the patch uploaded there and report back whether it works.

Apr 21, 2009 at 11:17 PM
The patch worked!

I'm able to create Excel5 sheets now!!!

Excel2007 doesn't work,because (I suppose)  my php-version does not support the zip files: Fatal error: Class 'ZipArchive' not found in /var/www/vhosts/
Or is there a solution for that, too?

Anyway, thank you very much, koyama!
Apr 22, 2009 at 12:09 AM
Great that it is working, and I see that Maarten has already applied patch in source code.

Second error message is because zip extension is missing. You need to contact your web hosting provider and ask them to add the zip extension to the PHP installation.