我需要在linux环境下从windows系统共享文件夹读取目录到PHP脚本,但脚本显示错误"failed to open dir: No such file or directory"
如何在linux中使用php读取windows共享目录?
如果您可以使用以下挂载命令在Linux机器上挂载Windows共享,则这与PHP IMO无关:
mount -t cifs -o username=WINDOWS_USER_NAME ''''hostname''sharename /mnt/myshare
那么您应该能够从/mnt/myshare
中读取共享中的文件,就像PHP脚本中的任何其他文件一样。