symbiote/silverstripe-contextawareupload 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

symbiote/silverstripe-contextawareupload

最新稳定版本:2.0.0

Composer 安装命令:

composer require symbiote/silverstripe-contextawareupload

包简介

Automatic organization of uploaded files based on the site tree structure.

README 文档

README

Build Status Latest Stable Version Latest Unstable Version Total Downloads License

This module will make the default upload folder match the URL structure of the page you're uploading in, rather than just uploading to the Uploads folder or the default-site folder if you're using Multisites.

ie. If you upload a file to a page that can be visited at http://www.mysite.com/information/about-us, then that file will be available at http://www.mysite.com/assets/information/about-us/filename.jpg by default, rather than http://www.mysite.com/assets/Uploads.

Composer Install

composer require symbiote/silverstripe-contextawareupload:~2.0

Requirements

  • SilverStripe 4.1+
  • (Optional) Multisites

Documentation

Known limitations

Uploading files via a WYSIWYG field's "Insert Media" button or anything else using the AssetAdmin view will not be affected by this module. I'm hoping this issue will be fixed in the future, and it's been logged here: silverstripe/silverstripe-assets#159

In the meantime however, you can optionally apply an extension so that any files uploaded to the root folder of assets, gets moved into the desired folder. ie. if File::ParentID == 0, move to default folder.

SilverStripe\Assets\File:
  extensions:
    - Symbiote\ContextAwareUpload\ForceRootToDefaultExtension

Credits

统计信息

  • 总下载量: 4.71k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2018-09-10