php - 在 Zend Form 中使用外部 FTP 服务器进行文件上传
问题描述
我在 Zend 1.11 中有一个将文件上传到服务器的表单
$imageUploader = $this->createElement('file', 'docs');
$imageUploader->setDestination($uploadPath);
上传路径现在在同一台服务器上,但我想上传到外部 FTP 服务器。
当我将 uploadPath 设置为ftp://user:pass@externalserver.com:21/folder我得到“给定的目标不可写”但这个文件夹有 0777
如何建立与此 FTP 服务器的连接并在那里上传文件?
解决方案
推荐阅读
- c# - 如何在 C# 中通过 WordPressSharp 填充 ACF 转发器字段?
- c++ - 在 C++ 中迭代链表比在具有类似内存访问的 Go 中慢
- python - Python Discord Bot Prune 命令
- java - 从包含 txt 文件的 Maven 项目创建 JAR 文件
- svg - 动画从左到右,但我希望它是从右到左,为什么?
- ruby-on-rails - ActiveRecord::RecordInvalid: 验证失败: 电子邮件已被用于 minitest
- python - Anaconda/Python/VSCode:vscode 编辑器无法识别已安装的软件包
- c# - 如何在 foreach 循环中修改结构的属性?
- opentext - OpenText Content Server 10.x 使用什么搜索引擎?
- c++ - azure-iot-sdk-c API IoTHubClient_LL_DoWork() 失败并出现很多错误