dongtao9158 2013-04-17 14:39
浏览 44

如何使用ss3 Gallery模块创建文件夹

Hi,
I'm using the ss3 gallery module on my silverstripe project and i'd like to know if is it possible to create many folders than can own pictures.

This is my situation :
- I have a project page holder which allows some project pages
- I have some project pages with some data and some pictures

When i create a new project page and that i add some pictures, the pictures go in the asset/bulkUppload folder, the problem is this folder own all my projects pages pictures. I'd like to create a picture folder by project page so when for example i have to display my project page info, i can find easily its pictures ans display them

Does anyone have a clue of how it'd be possible?

Thanks, Thomas

  • 写回答

1条回答 默认 最新

  • duanrong5927 2013-04-25 13:39
    关注

    If your images are being uploaded in a bulkUpload folder it is likely that this module uses the GridFieldBulkEditingTools module (https://github.com/colymba/GridFieldBulkEditingTools).

    If this is the case, you can add this line for each GridFieldConfig:

    $config->getComponentByType('GridFieldBulkImageUpload')->setConfig( 'folderName', 'gallery/'.$this->ID );
    

    This would save the images in numbered subfolders for each page under assets/gallery. But you can change 'gallery/'.$this->ID to whatever you want...

    评论

报告相同问题?

悬赏问题

  • ¥170 如图所示配置eNSP
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效
  • ¥15 悬赏!微信开发者工具报错,求帮改
  • ¥20 wireshark抓不到vlan
  • ¥20 关于#stm32#的问题:需要指导自动酸碱滴定仪的原理图程序代码及仿真
  • ¥20 设计一款异域新娘的视频相亲软件需要哪些技术支持
  • ¥15 stata安慰剂检验作图但是真实值不出现在图上
  • ¥15 c程序不知道为什么得不到结果
  • ¥15 键盘指令混乱情况下的启动盘系统重装