Page 1 of 1

Is it possible to open the file within directories

Posted: Wed Oct 17, 2007 3:35 am
by vinoth
Hi all Peoples.

I am trying to write some contents on the file.
The file was present on some other directory.
Is it possible to open the file in some directory Using fopen()

Posted: Wed Oct 17, 2007 4:35 am
by s.dot
Yes, granted the file has sufficient permissions in the mode you're trying to open it in. If I understand your question right you want to open a file that's in a different directory. You can either use an absolute path like /home/me/public_html/path/to/file.php or a relative path if the file is navigable from the current directory.. path/to/file.php.

Posted: Wed Oct 17, 2007 9:29 am
by vinoth
Thanks scottayy

Its working fine