Click to See Complete Forum and Search --> : fopen fails with IIS if virtual directory ...
carloscuria
03-10-2003, 06:33 PM
With
In a virtual directory o new site ( non defalult site ) in IIS 5.
After traying several times to open a file in the same directory as the php script I realized the directory where fopen try to open the file is C:\winnt\system32.
It only happens if you are working with a virtual directory or a new site.
¿ Any clue ?
amchargue
03-12-2003, 05:43 PM
I don't have an answer for your question directly, but a tip -- the getcwd() function is useful to discover where the heck your files are going without doing a file find on your whole system.
not quite sure what your asking, but could you post a sample of what your talking about?
carloscuria
03-14-2003, 04:49 AM
Thanks for your interest. I'm going to try to explain the problem more detailed.
In IIS in you have the default web site with it's real directories within normaly c:\InetPub\wwwroot or you can create a virtual directory thats belong to another place of the file system, or you can as well create a new ( virtual ) site in another branch of the file system.
Suppose I have a php script "example.php" in C:\InetPub\wwwroot\realdir with the following sentence:
echo getcwd ();
The output of this line is:
C:\InetPub\wwwroot\realdir
Suppose now the same script in C:\popo and that you map c:\popo as a virtual directory or as a new site in IIS, now the output of the same line is:
C:\winnt\system32
Maybe the place were the php dll resides ?
I played a little with some directives in php.ini but without results.
Carlos
echo getcwd();
amchargue
03-20-2003, 05:32 PM
Interesting. I wish I could help, but I can't. Hope someone can.
PHP Builder
Copyright WebMediaBrands Inc. All Rights Reserved.