简体   繁体   English

在Yii上管理用户文件

[英]Managing user files on Yii

I have been using Yii for a few months. 我已经使用Yii几个月了。 I am working on a mid-size project that handles users, groups and some interaction between users (By example, users can make proposals in their groups, other users can comment on proposals, there are group moderators/administrators, and so on) 我正在处理一个中型项目,该项目处理用户,组和用户之间的某些交互(例如,用户可以在组中提出建议,其他用户可以对建议进行评论,还有组主持人/管理员,等等)

I am about to start a part of my project that involves managing user files. 我将开始我的项目的一部分,其中涉及管理用户文件。 Basically I will handle 2 kind of files: images and pdfs. 基本上,我将处理2种文件:图像和pdf。 Images will be grouped in galleries, each having a name and description. 图像将按画廊分组,每个画廊都有名称和描述。 Only the group administrators can create galleries (no restriction on the number of galleries) and upload files. 只有组管理员才能创建图库(没有画廊数量的限制)并上传文件。 Other users can see the pictures and files of their group only. 其他用户只能看到其群组的图片和文件。

As I said, I have been working with Yii for some months, but I can't find clear information on user files management. 正如我所说,我已经与Yii合作了几个月,但找不到关于用户文件管理的明确信息。 I have a few questions: 我有几个问题:

  1. What directory should I use to store files? 我应该使用哪个目录来存储文件? Is there some kind of standard for this? 有某种标准吗?

  2. What facilities are provided by Yii for file management? Yii提供了哪些工具来进行文件管理?

Hope you can give me ideas. 希望你能给我想法。 Thanks in advance 提前致谢

EDIT: simplified the number of questions :) 编辑:简化了问题的数量:)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM