Skip to content
Advertisement

How to decrease file size upload for non-admin users?

My site allows upload file size of up to 256 MB but I would like to limit my site users to only 1 MB max and keep the maximum 256 MB for the admins. All solutions I found only show how to increase the upload limit, but not decrease for specific roles.

I tried the following but it didn’t work:

JavaScript

Advertisement

Answer

This seems like what you’re asking for is just an if/else?

JavaScript
User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement