问题描述:

When I use the PHP exec() command on a mounted shared folder I do not get an output. When I run the same command via the command line it works fine. Example:

My W:\ drive is a shared drive. When I am in CMD.exe and I run this command it works:

dir W:\

When I run this command in PHP I do not get an output:

shell_exec("dir W:\")

I don't think its a permissions issue; the user manually running the command on CMD.exe is the same user that PHP is using to run the script. I verified this by running shell_exec("whoami").

Please note, when I run shell_exec("C:\") it works fine, its simply not working on shared drives.

相关阅读:
Top