I use the following Apache directive to set the path for my web application's libraries. This allows me to set different paths on my production and dev machines:

<VirtualHost ...>
        ...
        php_value include_path "/Users/richard/Sites/example.com/inc"
</VirtualHost>


What's the equivalent for the command line? Should I do something like this?

$ export php_include_path="/Users/richard/Sites/example.com/inc"

<?php
        ini_set('include_path', getenv('php_include_path'));
?>

Is there an environment variable PHP will automatically read for includes? I'd prefer not to have to explicitly set it myself.

This seems like it should be really obvious, but my searching hasn't brought up anything.

Richard



_______________________________________________

UPHPU mailing list
[email protected]
http://uphpu.org/mailman/listinfo/uphpu
IRC: #uphpu on irc.freenode.net

Reply via email to