是否可以将文件保存到网络路径?
我想知道是否可以将文件写入到连接的服务器或其他网络路径,而不是本地系统。
我是否必须为此使用外部接口,或者我可以将其委托给 AIR 框架吗?
我非常确定 AIR 具有一定的安全预防措施来防止这种情况发生。
I was wondering if it would be possible to write a file, not to the local system, but to a connected server or other network path.
Would I have to use an external interface for this or can I entrust this to the AIR framework?
I'm pretty sure that AIR has certain security precautions to prevent this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
什么样的网络路径? SMB、FTP、HTTP、WebDav,..?
如果它安装在您的本地 PC 上,那么您应该能够像写入任何其他驱动器或文件系统一样对其进行写入。
What kind of network path? SMB, FTP, HTTP, WebDav, .. ?
If it's mounted on your local PC, then you should be able to write to it just like writing to any other drive or filesystem.
在 OSX 中将新文件写入网络驱动器上的文件夹:
我假设对于 Windows,您只需交换第一行中的网络驱动器路径。您不应指定协议(例如 file://、smb:// 等); File 构造函数的参数格式是本机路径(就像它出现在终端/命令 shell 中一样)。
要获取 OSX 中的路径,请使用 Finder 导航到目标网络文件夹。开始将文件夹拖动到其他位置,按苹果+空格键打开 Spotlight,然后继续将文件夹拖动到 Spotlight 中。或者,打开终端窗口并将文件夹拖到终端窗口中。
to write a new file to a folder on a networked drive in OSX:
i assume for Windows you would just swap the network drive path in the first line. you should not specify a protocol (e.g. file://, smb://, etc); the format of the parameter for the File constructor is the native path (as it would appear in a terminal / command shell).
to get the path in OSX, use the Finder to navigate to the target networked folder. begin dragging the folder somewhere else, hit apple+space to open Spotlight, and continue dragging the folder into Spotlight. alternately, open a Terminal window and drag the folder into the Terminal window.