As designed MG 2.1rc: filesize upload limit only in MB, not in KB possible

snoopy5

Well-known member
Affected version
MG 2.1rc
MG 2.1rc

In the usergroup settings there is the option to determine the maximum upload limit per file. Unfortunately, this works only in MB. If I put in i.e. 0.5 for 500KB, it changes that value after saving to 500 MB!

I doubt that many site owners want to allow their user to upload images which are always 1MB or bigger :)

193495
 
I suspect it's because MB has now become the default term used these days and that's due to the general size of files now compared to years ago. The use of the term KB is disappearing due to this and I'd guess that there are even some admins who may not know what a KB is.

TBH it's easier with current file sizes to specify that you are happy with 2MB files than to work out what that is in KB (2048 or 2000 depending on which definition you use; the former is the true definition, I can't remember which definition XenForo uses). I doubt there are many, if any admins who would restrict image uploads to their gallery to less than 1MB anyway. It might be useful to allow decimal increments though as I believe that you can currently only use integers as values.
 
I doubt there are many, if any admins who would restrict image uploads to their gallery to less than 1MB anyway.

This all depends for what you want to use the gallery for. If you want to use it for photocommunities, you will have very fast a hard time with your server hard disk space.

Embedding images is not a solution for photocommunities, because the discussion about images are worthless, if the link is sooner or later broken ;)
 
This all depends for what you want to use the gallery for. If you want to use it for photocommunities, you will have very fast a hard time with your server hard disk space.
I'd be highly surprised at photocommunies only allowing images that are less than 1MB. OK, it may be possible that the limit could be set at 1MB but less than 1MB? If anything I'd have thought they'd want to allow larger images as reducing image size reduces the quality. Even with small hosting offerings you usually get at least 20Gb space, so if 10Gb is set aside for photos that's 10000 photos of 1Mb each. More than this and you either have a big community and therefore need a better server anyway, or you have photo spamming users. You can always use the quota permission for that. ;)

As I said, decimal increments would be more useful rather than converting everything back into KB.
 
Unfortunately, this works only in MB. If I put in i.e. 0.5 for 500KB, it changes that value after saving to 500 MB!
It doesn't allow you to set decimal values at all, so there would be nothing to change it to. The browser should even block you from setting that value. I'm not sure if maybe you already had it set to 500 (thinking it was KB) so it reverted back to that.

I doubt that many site owners want to allow their user to upload images which are always 1MB or bigger :)
I doubt that many photo communities force such miniscule file sizes on their users. Of course restricting the dimensions is a sure fire way to ensure that file sizes are kept small.

Setting a maximum file size blocks the upload if it is exceeded. Setting maximum dimensions causes the image to be resized without blocking if it is exceeded. That in turn will automatically cause the file sizes to be smaller.

There are no plans to change it to KB and we can't support floats here as the permission system only supports whole numbers.
 
Setting a maximum file size blocks the upload if it is exceeded.


That is good to know for the future! So I have to find another way also for the forum-threads with images, not only for MG.

Something like this for XF 1.5x:



And that for XF 2.x

 
Top Bottom