Jim Lucas wrote:
Iv Ray wrote:
Jim Lucas wrote:
So, saying that it is outside the source does not tell me if it is
outside the document root.
A, right.
It is outside the document root.
Use your include_path php_ini setting
A, right...
Didn't think of it.
Actually, I do not like the
Richard Heyes wrote:
i need a way to get the path to the parent folder of the folder i am
in. one dirty way i found is this -
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR .
.. . DIRECTORY_SEPARATOR .
config.php);
i can also explode() and
hi all,
i need a way to get the path to the parent folder of the folder i am in.
one dirty way i found is this -
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR .
.. . DIRECTORY_SEPARATOR .
config.php);
i can also explode() and reassemble all
Personally I use.
?php require_once(dirname(dirname(__FILE__)).'/config.php');
I think it's what most people do.
/James Dempster
On Wed, Jun 18, 2008 at 1:31 PM, Iv Ray [EMAIL PROTECTED] wrote:
hi all,
i need a way to get the path to the parent folder of the folder i am in.
one dirty way
James Dempster wrote:
Personally I use.
?php require_once(dirname(dirname(__FILE__)).'/config.php');
I think it's what most people do.
A... very interesting, thanks.
To get the path only I did this -
$path = dirname(__FILE__);
$parts= explode(DIRECTORY_SEPARATOR, $path);
On 18 Jun 2008, at 13:57, Iv Ray wrote:
James Dempster wrote:
Personally I use.
?php require_once(dirname(dirname(__FILE__)).'/config.php');
I think it's what most people do.
A... very interesting, thanks.
To get the path only I did this -
$path = dirname(__FILE__);
$parts
Stut wrote:
On 18 Jun 2008, at 13:57, Iv Ray wrote:
James Dempster wrote:
Personally I use.
?php require_once(dirname(dirname(__FILE__)).'/config.php');
I think it's what most people do.
A... very interesting, thanks.
To get the path only I did this -
$path = dirname(__FILE__);
Stut wrote:
$path = dirname(dirname(__FILE__));
That will get you the parent directory.
-Stut
A,... right! - me and my limited thinking... - dirname() gives the
parent of a file AND of a directory, right.
Thanks,
Iv
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
Jim Lucas wrote:
Iv,
tell me why you are wanting to do this?
If it is the reason I think it is, I can give you a better way to
accomplish this.
I have the source and a configuration file, which I want outside the
source - it is different from server to server.
The easiest is to have the
Iv Ray wrote:
Jim Lucas wrote:
Iv,
tell me why you are wanting to do this?
If it is the reason I think it is, I can give you a better way to
accomplish this.
I have the source and a configuration file, which I want outside the
source - it is different from server to server.
The easiest
i need a way to get the path to the parent folder of the folder i am in.
one dirty way i found is this -
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR .
.. . DIRECTORY_SEPARATOR .
config.php);
i can also explode() and reassemble all folders
11 matches
Mail list logo