Re: relative paths with "require"
| From: | Joey Morwick | Date: | Wed, 20 Oct 2004 14:53:03 +0000 |
| Subject: | Re: relative paths with "require" | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-199895@lists.php.net to get a copy of this message | ||
Greg Donald wrote:
> Did you check the open_basedir setting? That will make php act as you
> described.
We don't have open_basedir set, but our problem is slightly different. If
you were to execute only a.php in my previous example, there would be no
error since the current directory would be /test/a. The problem is, if you
execute index.php and then when index.php requires a.php, a.php will be
executed with /test as the current directory instead of /test/a. We have
access to the /test directory. If you change the link in a.php to
"b/b.php" instead of "../b/b.php", it will work when you execute index.php,
but not when you execute a.php by itself.
--
~Joey Morwick