Jump to content

Include_path directory


Recommended Posts

I don't understand how to show the page in localhost if I use include path. Recently after installing MDB2, my include_path is change to like that ".;C;\php5\pear". Even I uncomment the "include_path = ".;c:\php\includes" in php.ini, it still cannot change it back.

The configure of the doc root is like that doc_root ="C:\Program Files\Apache Group\Apache\htdocs\". I put my php file in htdoc folder. if my code "ini_set("include_path", "./MDB2.php");" it shows MDB2 class is not found.

Does anyone tell me how to solve the problem?

Thanks
Link to comment
https://forums.phpfreaks.com/topic/29205-include_path-directory/
Share on other sites

Looks like PHP is not finding the php.ini you're editing. Copy your php.ini to the WINDOWS folder (C:\WINDOWS) now restart Apache. PHP should now be using the correct php.ini

Also include_path is used to define paths to directories only and not files. You include a file using the include or require functions.

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.