/ Web Development / PHP
Article ID: 00101Rating: 3.4 / 5.0 (5 votes)
Views: 4239
Created: Jan-17-2003
How do I set PHP include_path?
Issue
How do I set PHP include_path?
Solution
There are 2 ways you can set your PHP include_path:
- Use the function ini_set(). For example if you wanted to set your PHP include_path to ".:../:./include:../include" then you would do this in your PHP code:
ini_set("include_path", ".:../:./include:../include"); -
Make an php.ini file in the public_html folder, and inside that file put the following on one line:
include_path = ".:/php/includes"
