Jump to content

After PHP upgrade, include/path problems


Recommended Posts

I just upgraded to PHP 5, running on Xitami on my Windows home system. Now any scripts that have include/require lines don't work:

 

Warning: include_once(./include/common.inc.php): failed to open stream: No such file or directory in E:\dev\Xitami\webpages\gallery\index.php on line 30

Warning: include_once(): Failed opening './include/common.inc.php' for inclusion (include_path='.') in E:\dev\Xitami\webpages\gallery\index.php on line 30

Warning: include(./include/section_init.inc.php): failed to open stream: No such file or directory in E:\dev\Xitami\webpages\gallery\index.php on line 31

Warning: include(): Failed opening './include/section_init.inc.php' for inclusion (include_path='.') in E:\dev\Xitami\webpages\gallery\index.php on line 31

 

My include_path is (I just deleted the other default one because I don't have any include files there; it doesn't make a difference):

include_path = "."

 

Including files that are in the existing directory like include("header.php") works fine, as does "directory/header.php". Why doesn't "./" work? It used to work fine on my previous version, so it must be something with my install of the new PHP.

 

Please help!

Link to comment
https://forums.phpfreaks.com/topic/45186-after-php-upgrade-includepath-problems/
Share on other sites

So you have E:\dev\Xitami\webpages\gallery\include\section_init.inc.php right?  Because thats what its trying to load.

 

Yes, those files all exist. Like I said, it used to work under the old version of PHP, but with that version I didn't have GD loaded and I wanted to upgrade anyway. Now only my most basic PHP stuff works, whereas anything with that kind of path reference "./" doesn't.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.