Re: Specifying file paths in Windows

From: Date: Wed, 21 Jan 2004 01:31:20 +0000
Subject: Re: Specifying file paths in Windows
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-175257@lists.php.net to get a copy of this message
try removing the dot and / so if (is_file("filedir/test.txt")) echo "Found it!"; else echo "Not found"; that should work on windows and unix platforms, i dont think windows likes the single dot, but you can use relative referencing, by just using the directory name. -- Luke "Todd Cary" <todd@aristesoftware.com> wrote in message news:20040120232459.38844.qmail@pb1.pair.com... > The \filedir is under the phpcode directory > > c:\webroot > | > |--\application > | > |--\php_code > | > |--\filedir > > > Eric Bolikowski wrote: > > > "Todd Cary" <todd@aristesoftware.com> wrote in message > > news:20040120230641.62376.qmail@pb1.pair.com... > > > >>I moved an application from Linux to my Client's NT system and is_file > >>cannot file the file on the NT system. My directory structure is as > >>follows: > >> > >>c:\webroot > >> \application > >> \php_code > >> \filedir > >> > >>The code is > >> > > > > //two dots! > > > >>if (is_file("../filedir/test.txt")) echo "Found it!"; > >>else echo "Not found"; > >> > >>This is working with Linux, but it does not work with NT. Can someone > >>tell me why it does not work? > >> > >>Todd

« previous php.general (#175257) next »