Hey guys,

why there isn't an option to set the upload size limit per role?

Thanks

Yannick

Comments

quicksketch’s picture

Because this option doesn't make any sense. Why would you discourage your users from creating content? Or worse, users that need to free up space might go back and start deleting files that are in use to make it so they can create more nodes. As an alternative you can limit total file size per node or per field, and if you want to limit total file size, I suggest installing a module to limit the number of nodes that user can create.

yannickoo’s picture

Okay, I thought it's possible to say:

Normal (Authenticated users) can upload 10MB per field.
Pro users can upload 20MB
Premium users can upload 30M

That would be per node.

quicksketch’s picture

Yes, you can already limit *per file* and limit *per node*. However there is no way to specify different sizes for different user roles out-of-the-box, though this should be possible using CCK's hooks. However it would require a custom module to implement such functionality.

silurius’s picture

Subscribing.

quicksketch’s picture

Category: task » support
Status: Active » Closed (fixed)

Closing as this is answered as it can be. It won't be added as a feature at this point with FileField in core.

hermes_costell’s picture

"Because this option doesn't make any sense."

Incorrect.

Example: Audio file. Normal users have a 10MB file size limit. Paid users (in the inner circle) are allowed up to 50MB. Administrator user type has no limits.

yannickoo’s picture

hermes is right. i really cannot understand this statement.

kongoji’s picture

I don't know if this can help you, by the way I made a module to limit upload size per role:
http://drupal.org/project/filefield_role_limit

yannickoo’s picture

Pretty old issue but thanks for the information, great work!