Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
> echo '', var_dump( $_SERVER ), ''; > > for instance I cut/paste the following from an application of my, > the code lives in a centrally included file: > > /* define a webroot basepath for the datasyncer module */ > define('DS_WEBROOT', realpath(dirname(__FILE__).'/..')); > dirname! That's the

Re: [PHP] is_dir paths

2005-09-26 Thread Jochem Maas
Mark Rees wrote: var_dump (realpath('temp')); > I am trying to check whether /lists/admin/temp exists (which it does). This dir doesn't exists. The '/' at the beginning of path means: path is from root (unix) or from e.g. c:\ (windows) Outputs from var_dump(realpath("../../lists/admin/temp")

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
> > var_dump (realpath('temp')); > > I am trying to check whether /lists/admin/temp exists (which it does). > > This dir doesn't exists. The '/' at the beginning of path means: path is > from root (unix) or from e.g. c:\ (windows) > > Outputs from > > var_dump(realpath("../../lists/admin/temp")) >

Re: [PHP] is_dir paths

2005-09-26 Thread Ondrej Ivanič
Mark Rees wrote: That outputs (paths trimmed) string(56) "C:\...\htdocs\lists\admin" string(61) "C:\...\htdocs\lists\admin\temp" bool(false) var_dump (realpath("../../lists/admin/temp")); this outputs the same as var_dump (realpath('temp')); > I am trying to check whether /lists/admin/t

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
> > > what does the following output: > > > > > > var_dump (getcwd()); Sorry, this wasn't clear. I mean it outputs c:\...\htdocs\lists\admin Not sure about the permissions. I'm using windows 2000, and the 'temp' directory has the same user permissions as the rest of the htdocs folder > > what

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
> > what does the following output: > > > > var_dump (getcwd()); This outputs a fully qualified path to the current working directory (/lists/admin) Not sure about the permissions. I'm using windows 2000, and the 'temp' directory has the same user permissions as the rest of the htdocs foler > >

[PHP] is_dir paths

2005-09-26 Thread Mark Rees
Hello I am having trouble with is_dir I am trying to check whether /lists/admin/temp exists (which it does). However, I cannot get the function to work by specifying the path as above - it only works if I do it relative to the current working directory. So: -- www.itsagoodprice.com - top-brand

Re: [PHP] is_dir paths

2005-09-26 Thread Ondrej Ivanič
Jochem Maas wrote: what does the following output: var_dump (getcwd()); I have better question: what does the following output: var_dump (realpath(getcwd())); var_dump (realpath('temp')); var_dump (realpath("/lists/admin/temp")); -- Ondrej Ivanic ([EMAIL PROTECTED]) -- PHP General Mailing

Re: [PHP] is_dir paths

2005-09-26 Thread Jochem Maas
Mark Rees wrote: Hello I am having trouble with is_dir I am trying to check whether /lists/admin/temp exists (which it does). However, I cannot get the function to work by specifying the path as above - it only works if I do it relative to the current working directory. So: var_dump (is_dir(g

[PHP] is_dir paths

2005-09-26 Thread Mark Rees
Hello I am having trouble with is_dir I am trying to check whether /lists/admin/temp exists (which it does). However, I cannot get the function to work by specifying the path as above - it only works if I do it relative to the current working directory. So: var_dump (is_dir(getcwd())); var_dump