modera/file-uploader-bundle
Composer 安装命令:
composer require modera/file-uploader-bundle
包简介
README 文档
README
The bundle simplifies and introduces a consistent approach to uploading and storing uploaded files.
Installation
Step 1: Download the Bundle
composer require modera/file-uploader-bundle:5.x-dev
This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.
Step 2: Enable the Bundle
This bundle should be automatically enabled by Flex.
In case you don't use Flex, you'll need to manually enable the bundle by
adding the following line in the config/bundles.php file of your project:
<?php // config/bundles.php return [ // ... Modera\FileRepositoryBundle\ModeraFileRepositoryBundle::class => ['all' => true], // if you still don't have it Modera\FileUploaderBundle\ModeraFileUploaderBundle::class => ['all' => true], ];
Step 3: Add routing
// config/routes.yaml file_uploader: resource: "@ModeraFileUploaderBundle/Resources/config/routing.yml"
Step 4: Enable uploader
// config/packages/modera.yaml modera_file_uploader: is_enabled: true
Documentation
Before you can upload files you need to create a repository that will host them, for instructions please see ModeraFileRepositoryBundle.
Once you have a repository configured, from web you can send request with files to uploader gateway URL ( configured by
modera_file_uploader/url configuration property, default value is uploader-gateway ) and it will upload them and
put to a configured repository. For example, javascript pseudo code:
filesForm.submit({ url: 'uploader-gateway', params: { _repository: 'my_files' } });
Request parameter _repository will be used to determine what repository to use to store uploaded files. By default
all repositories are exposed to web and files can be uploaded to them, this feature is controller by expose_all_repositories
configuration property.
Licensing
This bundle is under the MIT license. See the complete license in the bundle: Resources/meta/LICENSE
modera/file-uploader-bundle 适用场景与选型建议
modera/file-uploader-bundle 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 4.03k 次下载、GitHub Stars 达 0, 最近一次更新时间为 2015 年 01 月 12 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 modera/file-uploader-bundle 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 modera/file-uploader-bundle 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 4.03k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 11
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-01-12